List:Commits« Previous MessageNext Message »
From:Brian Aker Date:December 6 2006 8:26pm
Subject:bk commit into 5.1 tree (baker:1.2345)
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of baker. When baker 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-12-06 20:26:10+01:00, baker@stripped +2 -0
  Merge bk-internal.mysql.com:/data0/bk/mysql-5.1
  into  bk-internal.mysql.com:/data0/bk/mysql-5.1-arch
  MERGE: 1.2343.1.6

  sql/item_func.cc@stripped, 2006-12-06 20:26:05+01:00, baker@stripped +0 -0
    Auto merged
    MERGE: 1.337.1.1

  sql/sql_yacc.yy@stripped, 2006-12-06 20:26:05+01:00, baker@stripped +0 -0
    Auto merged
    MERGE: 1.521.1.1

# 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:	baker
# Host:	bk-internal.mysql.com
# Root:	/data0/bk/mysql-5.1-arch/RESYNC

--- 1.338/sql/item_func.cc	2006-12-06 20:26:17 +01:00
+++ 1.339/sql/item_func.cc	2006-12-06 20:26:17 +01:00
@@ -897,7 +897,8 @@
 
 longlong Item_func_signed::val_int_from_str(int *error)
 {
-  char buff[MAX_FIELD_WIDTH], *end;
+  char buff[MAX_FIELD_WIDTH], *end, *start;
+  uint32 length;
   String tmp(buff,sizeof(buff), &my_charset_bin), *res;
   longlong value;
 
@@ -913,13 +914,21 @@
     return 0;
   }
   null_value= 0;
-  end= (char*) res->ptr()+ res->length();
-  value= my_strtoll10(res->ptr(), &end, error);
-  if (*error > 0 || end != res->ptr()+ res->length())
+  start= (char *)res->ptr();
+  length= res->length();
+
+  end= start + length;
+  value= my_strtoll10(start, &end, error);
+  if (*error > 0 || end != start+ length)
+  {
+    char err_buff[128];
+    String err_tmp(err_buff,(uint32) sizeof(err_buff), system_charset_info);
+    err_tmp.copy(start, length, system_charset_info);
     push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN,
                         ER_TRUNCATED_WRONG_VALUE,
                         ER(ER_TRUNCATED_WRONG_VALUE), "INTEGER",
-                        res->c_ptr());
+                        err_tmp.c_ptr());
+  }
   return value;
 }
 

--- 1.522/sql/sql_yacc.yy	2006-12-06 20:26:17 +01:00
+++ 1.523/sql/sql_yacc.yy	2006-12-06 20:26:17 +01:00
@@ -6426,7 +6426,7 @@
             }
           }
           /* Temporary placing the result of find_udf in $3 */
-          lex->current_select->udf_list.push_front(udf);
+          $<udf>$= udf;
 #endif
         }
         udf_expr_list ')'
@@ -6454,10 +6454,10 @@
           {
 #ifdef HAVE_DLOPEN
             /* Retrieving the result of find_udf */
-            udf_func *udf;
+            udf_func *udf= $<udf>3;
             LEX *lex= Lex;
 
-            if (NULL != (udf= lex->current_select->udf_list.pop()))
+            if (udf)
             {
               if (udf->type == UDFTYPE_AGGREGATE)
               {
@@ -6553,7 +6553,6 @@
 udf_expr:
 	remember_name expr remember_end select_alias
 	{
-          udf_func *udf= Select->udf_list.head();
           /*
            Use Item::name as a storage for the attribute value of user
            defined function argument. It is safe to use Item::name
@@ -6562,20 +6561,10 @@
           */
 	  if ($4.str)
           {
-            if (!udf)
-            {
-              /*
-                Disallow using AS to specify explicit names for the arguments
-                of stored routine calls
-              */
-              yyerror(ER(ER_SYNTAX_ERROR));
-              YYABORT;
-            }
-
             $2->is_autogenerated_name= FALSE;
 	    $2->set_name($4.str, $4.length, system_charset_info);
           }
-	  else if (udf)
+	  else
 	    $2->set_name($1, (uint) ($3 - $1), YYTHD->charset());
 	  $$= $2;
 	}
Thread
bk commit into 5.1 tree (baker:1.2345)Brian Aker6 Dec