List:Commits« Previous MessageNext Message »
From:Ole John Aske Date:October 4 2012 7:37am
Subject:bzr push into mysql-5.1-telco-7.0 branch (ole.john.aske:4994 to 4995)
Bug#14648712
View as plain text  
 4995 Ole John Aske	2012-10-04
      Fix for Bug#14648712 CALLING PROGERROR WITHOUT THE THIRD ARGUMENT RESULTS IN SIGSEGV
      
      The function ndb_basename() is called from ErrorReporter::handleError() with
      'problemData' as argument. As problemData is allowed to be NULL, that used to
      crash ndb_basename() when 'strlen()' was called.
      
      This fix will check for NULL argument to ndb_basename() and then
      return NULL. The returned NULL value is then later correctly 
      handled in ::WriteMessage() and EvenLogger::info() which ::handleErrro()
      may then later call with a NULL argument.

    modified:
      storage/ndb/src/kernel/error/ErrorReporter.cpp
 4994 Ole John Aske	2012-10-04
      Fix for memory leak in testSpj.cpp:
      
      HugoQueryBuilder::createQuery() takes the argument 'bool takeOwnership = false',
      where 'takeOwnerShip' decides whether the caller will be responsible (== true)
      for destruction the query object. Default behavior (==false) is that all created
      query objects will be destructed together with the HugoQueryBuilder.
      
      testSpj incorrectly supplied the 'Ndb*' as first argument to ::creatQuery().
      This was auto converted to a boolean 'true' value when 'Ndb* != NULL' - thus
      incorrectly specifying that testSpj will destruct the query objects.
      
      This fix removes the incorrect argument, such that the default 'false' value
      is used instead. 

    modified:
      storage/ndb/test/ndbapi/testSpj.cpp
=== modified file 'storage/ndb/src/kernel/error/ErrorReporter.cpp'
--- a/storage/ndb/src/kernel/error/ErrorReporter.cpp	2012-01-19 06:21:05 +0000
+++ b/storage/ndb/src/kernel/error/ErrorReporter.cpp	2012-10-04 07:27:22 +0000
@@ -49,6 +49,9 @@ static
 const char *
 ndb_basename(const char * path)
 {
+  if (path == NULL)
+    return NULL;
+
   const char separator = '/';
   const char * p = path + strlen(path);
   while (p > path && p[0] != separator)

No bundle (reason: useless for push emails).
Thread
bzr push into mysql-5.1-telco-7.0 branch (ole.john.aske:4994 to 4995)Bug#14648712Ole John Aske4 Oct