List:Commits« Previous MessageNext Message »
From:Mikael Ronstrom Date:October 10 2012 9:17am
Subject:bzr push into mysql-5.5-cluster-7.2 branch (mikael.ronstrom:3982 to 3983)
View as plain text  
 3983 Mikael Ronstrom	2012-10-10
      Fixed Win64 compiler warnings

    modified:
      storage/ndb/src/common/portlib/NdbThread.c
      storage/ndb/src/ndbapi/TransporterFacade.cpp
      storage/ndb/src/ndbapi/trp_client.hpp
 3982 Mikael Ronstrom	2012-10-08
      Fixed a behavioural change

    modified:
      storage/ndb/src/ndbapi/NdbTransaction.cpp
=== modified file 'storage/ndb/src/common/portlib/NdbThread.c'
--- a/storage/ndb/src/common/portlib/NdbThread.c	revid:mikael.ronstrom@stripped
+++ b/storage/ndb/src/common/portlib/NdbThread.c	revid:mikael.ronstrom@stripped
@@ -490,6 +490,8 @@ NdbThread_UnlockCPU(struct NdbThread* pT
     {
       error_no = errno;
     }
+#else
+    (void)ret;
 #endif
   }
   return error_no;

=== modified file 'storage/ndb/src/ndbapi/TransporterFacade.cpp'
--- a/storage/ndb/src/ndbapi/TransporterFacade.cpp	revid:mikael.ronstrom@stripped
+++ b/storage/ndb/src/ndbapi/TransporterFacade.cpp	revid:mikael.ronstrom@stripped
@@ -987,21 +987,32 @@ TransporterFacade::configure(NodeId node
   if (!m_send_buffer.inited())
   {
     Uint32 total_send_buffer = 0;
+    Uint64 total_send_buffer64;
+    size_t total_send_buffer_size_t;
     iter.get(CFG_TOTAL_SEND_BUFFER_MEMORY, &total_send_buffer);
 
-    if (total_send_buffer == 0)
+    total_send_buffer64 = total_send_buffer;
+    if (total_send_buffer64 == 0)
     {
-      total_send_buffer = theTransporterRegistry->get_total_max_send_buffer();
+      total_send_buffer64 = theTransporterRegistry->get_total_max_send_buffer();
     }
 
     Uint64 extra_send_buffer = 0;
     iter.get(CFG_EXTRA_SEND_BUFFER_MEMORY, &extra_send_buffer);
 
-    total_send_buffer += extra_send_buffer;
-    if (!m_send_buffer.init(total_send_buffer))
+    total_send_buffer64 += extra_send_buffer;
+#if SIZEOF_CHARP == 4
+    /* init method can only handle 32-bit sizes on 32-bit platforms */
+    if (total_send_buffer64 > 0xFFFFFFFF)
+    {
+      total_send_buffer64 = 0xFFFFFFFF;
+    }
+#endif
+    total_send_buffer_size_t = (size_t)total_send_buffer64;
+    if (!m_send_buffer.init(total_send_buffer_size_t))
     {
       ndbout << "Unable to allocate "
-             << total_send_buffer
+             << total_send_buffer_size_t
              << " bytes of memory for send buffers!!" << endl;
       return false;
     }

=== modified file 'storage/ndb/src/ndbapi/trp_client.hpp'
--- a/storage/ndb/src/ndbapi/trp_client.hpp	revid:mikael.ronstrom@stripped
+++ b/storage/ndb/src/ndbapi/trp_client.hpp	revid:mikael.ronstrom@stripped
@@ -140,7 +140,7 @@ private:
    * This is used for sending
    */
   Uint32 m_send_nodes_cnt;
-  Uint8 m_send_nodes_list[MAX_NODES];
+  NodeId m_send_nodes_list[MAX_NODES];
   NodeBitmask m_send_nodes_mask;
   TFBuffer* m_send_buffers;
 };

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.5-cluster-7.2 branch (mikael.ronstrom:3982 to 3983) Mikael Ronstrom10 Oct