Commit e37db41f authored by unknown's avatar unknown
Browse files

Merge joreland@bk-internal.mysql.com:/home/bk/mysql-5.0

into mysql.com:/home/jonas/src/mysql-5.0


configure.in:
  Auto merged
libmysqld/Makefile.am:
  Auto merged
strings/ctype-big5.c:
  Auto merged
strings/ctype-ucs2.c:
  Auto merged
parents 7a6c62a1 a59dee6c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -214,4 +214,4 @@ drop table if exists t1_c,t2_c,t3_c,t4_c,t5_c,t6_c,t7_c,t8_c,t9_c;
# Test BUG#10287
#

--exec $NDB_TOOLS_DIR/ndb_select_all -d sys -D , SYSTAB_0 | grep 520093696
--exec $NDB_TOOLS_DIR/ndb_select_all --no-defaults -d sys -D , SYSTAB_0 | grep 520093696
+7 −0
Original line number Diff line number Diff line
@@ -204,6 +204,13 @@ public:
  bool createSHMTransporter(struct TransporterConfiguration * config);
  bool createOSETransporter(struct TransporterConfiguration * config);

  /**
   * Get free buffer space
   *
   *   Get #free bytes in send buffer for <em>node</node>
   */
  Uint32 get_free_buffer(Uint32 node) const ;
  
  /**
   * prepareSend
   *
+5 −4
Original line number Diff line number Diff line
@@ -1025,7 +1025,8 @@ SCI_Transporter::initSCI() {
  DBUG_RETURN(true);
} 
 
 
 
 
 
Uint32
SCI_Transporter::get_free_buffer() const
{
  return (m_TargetSegm[m_ActiveAdapterId].writer)->get_free_buffer();
}
+2 −1
Original line number Diff line number Diff line
@@ -134,6 +134,7 @@ public:
   */ 
  bool getConnectionStatus(); 

  virtual Uint32 get_free_buffer() const;   
private: 
  SCI_Transporter(TransporterRegistry &t_reg,
                  const char *local_host,
+17 −0
Original line number Diff line number Diff line
@@ -157,6 +157,7 @@ public:

  inline Uint32 getWriteIndex() const { return m_writeIndex;}
  inline Uint32 getBufferSize() const { return m_bufferSize;}
  inline Uint32 get_free_buffer() const;
  
  inline void copyIndexes(SHM_Writer * standbyWriter);

@@ -213,4 +214,20 @@ SHM_Writer::updateWritePtr(Uint32 sz){
  * m_sharedWriteIndex = tWriteIndex;
}

inline
Uint32
SHM_Writer::get_free_buffer() const
{
  Uint32 tReadIndex  = * m_sharedReadIndex;
  Uint32 tWriteIndex = m_writeIndex;
  
  Uint32 free;
  if(tReadIndex <= tWriteIndex){
    free = m_bufferSize + tReadIndex - tWriteIndex;
  } else {
    free = tReadIndex - tWriteIndex;
  }
  return free;
}
 
#endif
Loading