List:Commits« Previous MessageNext Message »
From:Magnus Blåudd Date:November 5 2010 12:10pm
Subject:bzr push into mysql-5.1-telco-7.1 branch (magnus.blaudd:3955 to 3956)
View as plain text  
 3956 Magnus Blåudd	2010-11-05 [merge]
      Merge 7.0 -> 7.1

    modified:
      storage/ndb/include/Makefile.am
      storage/ndb/test/ndbapi/testNdbApi.cpp
      storage/ndb/test/ndbapi/testPartitioning.cpp
      storage/ndb/test/src/NdbBackup.cpp
 3955 Magnus Blåudd	2010-11-05 [merge]
      Merge 7.0 -> 7.1

    modified:
      sql/ha_ndbcluster.cc
      sql/ha_ndbcluster.h
      sql/ha_ndbcluster_glue.h
      sql/ha_partition.cc
      storage/ndb/Makefile.am
      storage/ndb/ndb_configure.cmake
      storage/ndb/src/kernel/CMakeLists.txt
      storage/ndb/src/kernel/vm/CMakeLists.txt
=== modified file 'storage/ndb/include/Makefile.am'
--- a/storage/ndb/include/Makefile.am	2010-08-06 08:19:19 +0000
+++ b/storage/ndb/include/Makefile.am	2010-11-05 12:04:36 +0000
@@ -59,5 +59,5 @@ ndb_global.h \
 ndb_net.h
 
 EXTRA_DIST = debugger editline kernel logger mgmcommon \
-portlib transporter util CMakeLists.txt
+portlib transporter util CMakeLists.txt ndb_config.h.in
 

=== modified file 'storage/ndb/test/ndbapi/testNdbApi.cpp'
--- a/storage/ndb/test/ndbapi/testNdbApi.cpp	2010-10-06 08:59:33 +0000
+++ b/storage/ndb/test/ndbapi/testNdbApi.cpp	2010-11-05 10:26:02 +0000
@@ -2108,9 +2108,10 @@ testNdbRecordPkAmbiguity(NDBT_Context* c
       memset(attrRowBuf, 0, sizeOfTabRec);
       
       Uint32 pkVal= 0;
-      pkVal= *(Uint32*) NdbDictionary::getValuePtr(tabRec,
-                                                   keyRowBuf,
-                                                   0);
+      memcpy(&pkVal, NdbDictionary::getValuePtr(tabRec,
+                                                keyRowBuf,
+                                                0),
+             sizeof(pkVal));
 
       trans= pNdb->startTransaction();
       op= trans->readTuple(tabRec,

=== modified file 'storage/ndb/test/ndbapi/testPartitioning.cpp'
--- a/storage/ndb/test/ndbapi/testPartitioning.cpp	2010-06-15 09:04:11 +0000
+++ b/storage/ndb/test/ndbapi/testPartitioning.cpp	2010-11-05 10:26:02 +0000
@@ -958,15 +958,22 @@ dist_scan_body(Ndb* pNdb, int records, i
 
     if (usePrimary)
     {
-      /* Scanning the primary index, set bound on the pk */
-      int& dKeyVal= *((int*) NdbDictionary::getValuePtr(idxRecord,
-                                                        boundBuf,
-                                                        tab->getColumn(DistTabDKeyCol)->getAttrId()));
-      int& pKey2Val= *((int*) NdbDictionary::getValuePtr(idxRecord,
-                                                         boundBuf,
-                                                         tab->getColumn(DistTabPKey2Col)->getAttrId()));
-      dKeyVal= partValue;
-      pKey2Val= r;
+      {
+        int dKeyVal= partValue;
+        int pKey2Val= r;
+        /* Scanning the primary index, set bound on the pk */
+        memcpy(NdbDictionary::getValuePtr(idxRecord,
+                                          boundBuf,
+                                          tab->getColumn(DistTabDKeyCol)->getAttrId()),
+               &dKeyVal,
+               sizeof(dKeyVal));
+        memcpy(NdbDictionary::getValuePtr(idxRecord,
+                                          boundBuf,
+                                          tab->getColumn(DistTabPKey2Col)->getAttrId()),
+               &pKey2Val,
+               sizeof(pKey2Val));
+        
+      }
 
       NdbIndexScanOperation::IndexBound ib;
       ib.low_key= boundBuf;
@@ -999,10 +1006,14 @@ dist_scan_body(Ndb* pNdb, int records, i
     {
       Uint32 resultValAttrId= tab->getColumn(DistTabResultCol)->getAttrId();
       /* Scanning the secondary index, set bound on the result */
-      int& resultVal= *((int*) NdbDictionary::getValuePtr(idxRecord,
-                                                          boundBuf,
-                                                          resultValAttrId));
-      resultVal= r*r;
+      {
+        int resultVal= r*r;
+        memcpy(NdbDictionary::getValuePtr(idxRecord,
+                                          boundBuf,
+                                          resultValAttrId),
+               &resultVal,
+               sizeof(resultVal));
+      }
 
       NdbDictionary::setNull(idxRecord,
                              boundBuf,
@@ -1104,15 +1115,23 @@ dist_scan_body(Ndb* pNdb, int records, i
     
     while ((rc= pInfo.op->nextResult(&resultPtr, true, true)) == 0)
     {
-      int& dKeyVal= *((int*) NdbDictionary::getValuePtr(tabRecord,
-                                                        resultPtr,
-                                                        tab->getColumn(DistTabDKeyCol)->getAttrId()));
-      int& pKey2Val= *((int*) NdbDictionary::getValuePtr(tabRecord,
-                                                         resultPtr,
-                                                         tab->getColumn(DistTabPKey2Col)->getAttrId()));
-      int& resultVal= *((int*) NdbDictionary::getValuePtr(tabRecord,
-                                                          resultPtr,
-                                                          tab->getColumn(DistTabResultCol)->getAttrId()));
+      int dKeyVal;
+      memcpy(&dKeyVal, NdbDictionary::getValuePtr(tabRecord,
+                                                  resultPtr,
+                                                  tab->getColumn(DistTabDKeyCol)->getAttrId()),
+             sizeof(dKeyVal));
+
+      int pKey2Val;
+      memcpy(&pKey2Val, NdbDictionary::getValuePtr(tabRecord,
+                                                   resultPtr,
+                                                   tab->getColumn(DistTabPKey2Col)->getAttrId()),
+             sizeof(pKey2Val));
+
+      int resultVal;
+      memcpy(&resultVal, NdbDictionary::getValuePtr(tabRecord,
+                                                    resultPtr,
+                                                    tab->getColumn(DistTabResultCol)->getAttrId()),
+             sizeof(resultVal));
       
       if ((dKeyVal != pInfo.dKeyVal) ||
           (resultVal != (pKey2Val * pKey2Val)))

=== modified file 'storage/ndb/test/src/NdbBackup.cpp'
--- a/storage/ndb/test/src/NdbBackup.cpp	2010-09-23 08:24:52 +0000
+++ b/storage/ndb/test/src/NdbBackup.cpp	2010-11-05 10:47:24 +0000
@@ -49,6 +49,7 @@ NdbBackup::clearOldBackups()
 
   int retCode = 0;
 
+#ifndef _WIN32
   for(size_t i = 0; i < ndbNodes.size(); i++)
   {
     int nodeId = ndbNodes[i].node_id;
@@ -73,6 +74,7 @@ NdbBackup::clearOldBackups()
     if (res && retCode == 0)
       retCode = res;
   }
+#endif
 
   return retCode;
 }

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.1-telco-7.1 branch (magnus.blaudd:3955 to 3956) Magnus Blåudd5 Nov