List:Commits« Previous MessageNext Message »
From:Jonas Oreland Date:November 10 2008 5:41pm
Subject:bzr push into mysql-5.1 branch (jonas:3070 to 3071)
View as plain text  
 3071 Jonas Oreland	2008-11-10
      ndb - fix segv on solaris-64-bit (gcc), due incorrect handling of union between pointer and integer
modified:
  storage/ndb/src/mgmsrv/ConfigInfo.cpp
  storage/ndb/src/mgmsrv/ConfigInfo.hpp

 3070 Frazer Clement	2008-11-10 [merge]
      Merge 6.3->6.4
modified:
  mysql-test/suite/ndb/r/ndb_blob.result
  mysql-test/suite/ndb/t/ndb_blob.test

=== modified file 'storage/ndb/src/mgmsrv/ConfigInfo.cpp'
--- a/storage/ndb/src/mgmsrv/ConfigInfo.cpp	2008-11-07 13:23:15 +0000
+++ b/storage/ndb/src/mgmsrv/ConfigInfo.cpp	2008-11-10 14:43:52 +0000
@@ -4521,13 +4521,14 @@ ConfigInfo::ParamInfoIter::ParamInfoIter
     const ConfigInfo::ParamInfo & param = info.m_ParamInfo[j];
     if (param._type == ConfigInfo::CI_SECTION &&
         param._paramId == section &&
-        (section_type == (Uint32)~0 || param._section_type == section_type))
+        (section_type == ~(Uint32)0 || 
+         Uint32(param._section_type) == section_type))
     {
       m_section_name= param._section;
-      break;
+      return;
     }
   }
-  assert(m_section_name);
+  abort();
 }
 
 

=== modified file 'storage/ndb/src/mgmsrv/ConfigInfo.hpp'
--- a/storage/ndb/src/mgmsrv/ConfigInfo.hpp	2008-10-21 12:41:59 +0000
+++ b/storage/ndb/src/mgmsrv/ConfigInfo.hpp	2008-11-10 14:43:52 +0000
@@ -83,7 +83,8 @@ public:
      */
     union {
       const char*  _default;
-      Uint32       _section_type; // if _type = CI_SECTION
+      UintPtr      _section_type; // if _type = CI_SECTION
+      /** NOTE must be UintPtr to be of same size as _default */
     };
     const char*    _min;
     const char*    _max;

Thread
bzr push into mysql-5.1 branch (jonas:3070 to 3071) Jonas Oreland10 Nov