List:Commits« Previous MessageNext Message »
From:ahristov Date:January 18 2006 6:44pm
Subject:bk commit into 5.1 tree (andrey:1.2059) BUG#16434
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of andrey. When andrey 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.2059 06/01/18 19:42:58 andrey@lmy004. +3 -0
  fix for bug#16434 (Events: Illegal dates don't cause errors)
  WL#1034 (Internal CRON)

  sql/sql_yacc.yy
    1.437 06/01/18 19:41:45 andrey@lmy004. +12 -1
    handle error code returned by event_timed::init_starts()

  sql/share/errmsg.txt
    1.72 06/01/18 19:41:43 andrey@lmy004. +5 -1
    add and change error messages

  sql/event_timed.cc
    1.18 06/01/18 19:41:41 andrey@lmy004. +0 -3
    remove bogus check

# 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:	andrey
# Host:	lmy004.
# Root:	/work/mysql-5.1-bug16434

--- 1.436/sql/sql_yacc.yy	2006-01-13 17:44:45 +01:00
+++ 1.437/sql/sql_yacc.yy	2006-01-18 19:41:45 +01:00
@@ -1467,7 +1467,18 @@
           {
             LEX *lex= Lex;
             if (!lex->et_compile_phase)
-              lex->et->init_starts(YYTHD, $2);
+            {
+              switch (lex->et->init_starts(YYTHD, $2)) {
+              case EVEX_PARSE_ERROR:
+                yyerror(ER(ER_SYNTAX_ERROR));
+                YYABORT;
+                break;
+              case EVEX_BAD_PARAMS:
+                my_error(ER_EVENT_STARTS_INVALID, MYF(0));
+                YYABORT;
+                break;
+              }
+            }
           }
       ;
 

--- 1.17/sql/event_timed.cc	2006-01-12 16:51:19 +01:00
+++ 1.18/sql/event_timed.cc	2006-01-18 19:41:41 +01:00
@@ -238,9 +238,6 @@
   if (new_starts->fix_fields(thd, &new_starts))
     DBUG_RETURN(EVEX_PARSE_ERROR);
 
-  if (new_starts->val_int() == MYSQL_TIMESTAMP_ERROR)
-    DBUG_RETURN(EVEX_BAD_PARAMS);
-
   if ((not_used= new_starts->get_date(&ltime, TIME_NO_ZERO_DATE)))
     DBUG_RETURN(EVEX_BAD_PARAMS);
 

--- 1.71/sql/share/errmsg.txt	2006-01-12 10:04:54 +01:00
+++ 1.72/sql/share/errmsg.txt	2006-01-18 19:41:43 +01:00
@@ -5760,7 +5760,7 @@
 ER_EVENT_INTERVAL_NOT_POSITIVE
         eng "INTERVAL must be positive"
 ER_EVENT_ENDS_BEFORE_STARTS
-        eng "ENDS must be after STARTS"
+        eng "ENDS is either invalid or before STARTS"
 ER_EVENT_EXEC_TIME_IN_THE_PAST
         eng "Activation (AT) time is in the past"
 ER_EVENT_OPEN_TABLE_FAILED
@@ -5777,6 +5777,10 @@
         eng "Error during compilation of event's body"
 ER_EVENT_SAME_NAME
         eng "Same old and new event name"
+ER_EVENT_STARTS_INVALID
+        eng "STARTS is invalid"
+ER_EVENT_ENDS_INVALID
+        eng "ENDS is invalid"
 ER_EVENT_DATA_TOO_LONG
         eng "Data for column '%s' too long"
 ER_DROP_INDEX_FK
Thread
bk commit into 5.1 tree (andrey:1.2059) BUG#16434ahristov18 Jan