MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:ramil Date:August 29 2006 9:38am
Subject:bk commit into 4.1 tree (ramil:1.2538) BUG#21142
View as plain text  
Below is the list of changes that have just been committed into a local
4.1 repository of ram. When ram 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@stripped, 2006-08-29 14:38:02+05:00, ramil@stripped +1 -0
  Fix for bug #21142: Malformed insert causes a segmentation fault.
    - possible stack overflow fixed.

  client/mysql.cc@stripped, 2006-08-29 14:38:00+05:00, ramil@stripped +2 -2
    Fix for bug #21142: Malformed insert causes a segmentation fault.
      - as 'line' may be longer than 'buff' we must take into account its length.

# 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:	ramil
# Host:	myoffice.izhnet.ru
# Root:	/usr/home/ram/work/bug21142/my41-bug21142

--- 1.219/client/mysql.cc	2006-08-29 14:38:07 +05:00
+++ 1.220/client/mysql.cc	2006-08-29 14:38:07 +05:00
@@ -2615,7 +2615,7 @@
   bzero(buff, sizeof(buff));
   if (buffer)
   {
-    strmov(buff, line);
+    strmake(buff, line, sizeof(buff) - 1);
     tmp= get_arg(buff, 0);
     if (tmp && *tmp)
     {
@@ -2729,7 +2729,7 @@
   char *tmp, buff[FN_REFLEN + 1];
 
   bzero(buff, sizeof(buff));
-  strmov(buff, line);
+  strmake(buff, line, sizeof(buff) - 1);
   tmp= get_arg(buff, 0);
   if (!tmp || !*tmp)
   {
Thread
bk commit into 4.1 tree (ramil:1.2538) BUG#21142ramil29 Aug