List:Commits« Previous MessageNext Message »
From:Martin Skold Date:June 21 2006 9:51am
Subject:bk commit into 5.0 tree (mskold:1.2194)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of marty. When marty does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet
  1.2194 06/06/21 09:50:41 mskold@stripped +1 -0
  Merge mysql.com:/home/marty/MySQL/mysql-5.0-backed
  into  mysql.com:/home/marty/MySQL/mysql-5.0

  sql/ha_ndbcluster.cc
    1.262 06/06/21 09:50:32 mskold@stripped +0 -0
    Auto merged

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	mskold
# Host:	linux.site
# Root:	/home/marty/MySQL/mysql-5.0/RESYNC

--- 1.261/sql/ha_ndbcluster.cc	2006-06-20 00:07:51 +02:00
+++ 1.262/sql/ha_ndbcluster.cc	2006-06-21 09:50:32 +02:00
@@ -771,10 +771,11 @@ int g_get_ndb_blobs_value(NdbBlob *ndb_b
   if (ndb_blob->blobsNextBlob() != NULL)
     DBUG_RETURN(0);
   ha_ndbcluster *ha= (ha_ndbcluster *)arg;
-  DBUG_RETURN(ha->get_ndb_blobs_value(ndb_blob));
+  DBUG_RETURN(ha->get_ndb_blobs_value(ndb_blob, ha->m_blobs_offset));
 }
 
-int ha_ndbcluster::get_ndb_blobs_value(NdbBlob *last_ndb_blob)
+int ha_ndbcluster::get_ndb_blobs_value(NdbBlob *last_ndb_blob,
+				       my_ptrdiff_t ptrdiff)
 {
   DBUG_ENTER("get_ndb_blobs_value");
 
@@ -807,7 +808,10 @@ int ha_ndbcluster::get_ndb_blobs_value(N
           if (ndb_blob->readData(buf, len) != 0)
             DBUG_RETURN(-1);
           DBUG_ASSERT(len == blob_len);
+          // Ugly hack assumes only ptr needs to be changed
+          field_blob->ptr+= ptrdiff;
           field_blob->set_ptr(len, buf);
+          field_blob->ptr-= ptrdiff;
         }
         offset+= blob_size;
       }
@@ -870,6 +874,7 @@ int ha_ndbcluster::get_ndb_value(NdbOper
       if (ndb_blob != NULL)
       {
         // Set callback
+	m_blobs_offset= buf - (byte*) table->record[0];
         void *arg= (void *)this;
         DBUG_RETURN(ndb_blob->setActiveHook(g_get_ndb_blobs_value, arg) != 0);
       }
@@ -4584,6 +4589,7 @@ ha_ndbcluster::ha_ndbcluster(TABLE *tabl
   m_ops_pending(0),
   m_skip_auto_increment(TRUE),
   m_blobs_pending(0),
+  m_blobs_offset(0),
   m_blobs_buffer(0),
   m_blobs_buffer_size(0),
   m_dupkey((uint) -1),
Thread
bk commit into 5.0 tree (mskold:1.2194)Martin Skold21 Jun