List:Internals« Previous MessageNext Message »
From:pem Date:October 21 2005 11:45am
Subject:bk commit into 5.0 tree (pem:1.2014)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of pem. When pem 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.2014 05/10/21 13:08:00 pem@stripped +1 -0
  Post-review fix.

  sql/sp_head.cc
    1.193 05/10/21 13:07:50 pem@stripped +4 -3
    Post-review fix; changed string copying method (+ fixed comment typo and indention).

# 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:	pem
# Host:	mysql.comhem.se
# Root:	/usr/home/pem/bug13941/mysql-5.0

--- 1.192/sql/sp_head.cc	2005-10-19 14:54:41 +02:00
+++ 1.193/sql/sp_head.cc	2005-10-21 13:07:50 +02:00
@@ -295,7 +295,7 @@
 
     /*
       For some functions, 's' is now pointing to an argument of the
-      function, which might be a local variable that it to be reused.
+      function, which might be a local variable that is to be reused.
       In this case, new(reuse, &rsize) below will call the destructor
       and 's' ends up pointing to freed memory.
       A somewhat ugly fix is to simply copy the string to our local one
@@ -304,7 +304,8 @@
      */
     if (reuse && s != &tmp && s != &it->str_value)
     {
-      tmp.copy(s->c_ptr(), s->length(), it->collation.collation);
+      if (tmp.copy((const String)(*s)))
+        DBUG_RETURN(NULL);
       s= &tmp;
     }
 
@@ -338,7 +339,7 @@
 
 return_null_item:
   CREATE_ON_CALLERS_ARENA(it= new(reuse, &rsize) Item_null(),
-                    use_callers_arena, &backup_arena);
+                          use_callers_arena, &backup_arena);
 end:
   it->rsize= rsize;
 
Thread
bk commit into 5.0 tree (pem:1.2014)pem21 Oct