List:Commits« Previous MessageNext Message »
From:ahristov Date:February 15 2006 10:32pm
Subject:bk commit into 5.1 tree (andrey:1.2110) BUG#17289
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.2110 06/02/15 22:32:25 andrey@lmy004. +1 -0
  more cosmetic before push of fix for bug#17289

  sql/event_timed.cc
    1.29 06/02/15 22:32:14 andrey@lmy004. +2 -6
    - fix comment
    - use mysql_change_db() this will check for us 

# 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-bug17289

--- 1.28/sql/event_timed.cc	2006-02-15 21:51:51 +01:00
+++ 1.29/sql/event_timed.cc	2006-02-15 22:32:14 +01:00
@@ -1061,6 +1061,7 @@ event_timed::get_create_event(THD *thd, 
 
   RETURNS
     0        success
+    -99      No rights on this.dbname.str
     -100     event in execution (parallel execution is impossible)
     others   retcodes of sp_head::execute_procedure()
 */
@@ -1089,16 +1090,12 @@ event_timed::execute(THD *thd, MEM_ROOT 
   if (!sphead && (ret= compile(thd, mem_root)))
     goto done;
   
-  thd->db= dbname.str;
-  thd->db_length= dbname.length;
-
   DBUG_PRINT("info", ("master_access=%d db_access=%d",
              thd->security_ctx->master_access,
thd->security_ctx->db_access));
   change_security_context(thd, &save_ctx);
   DBUG_PRINT("info", ("master_access=%d db_access=%d",
              thd->security_ctx->master_access,
thd->security_ctx->db_access));
-//  if (mysql_change_db(thd, dbname.str, 0))
-  if (!check_access(thd, EVENT_ACL,dbname.str, 0, 0, 0,is_schema_db(dbname.str)))
+  if (mysql_change_db(thd, dbname.str, 0))
   {
     List<Item> empty_item_list;
     empty_item_list.empty();
@@ -1113,7 +1110,6 @@ event_timed::execute(THD *thd, MEM_ROOT 
   restore_security_context(thd, save_ctx);
   DBUG_PRINT("info", ("master_access=%d db_access=%d",
              thd->security_ctx->master_access,
thd->security_ctx->db_access));
-  thd->db= 0;
 
   VOID(pthread_mutex_lock(&this->LOCK_running));
   running= false;
Thread
bk commit into 5.1 tree (andrey:1.2110) BUG#17289ahristov15 Feb