MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Alexander Nozdrin Date:February 7 2006 11:56am
Subject:bk commit into 5.2 tree (anozdrin:1.2097) BUG#15166
View as plain text  
Below is the list of changes that have just been committed into a local
5.2 repository of alik. When alik 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.2097 06/02/07 14:55:54 anozdrin@stripped +3 -0
  Fix merge (5.1 -> 5.2) of the patch for BUG#15166/15196.

  sql/sql_trigger.cc
    1.46 06/02/07 14:55:51 anozdrin@stripped +1 -1
    Updated according to the 5.1 data structures.

  sql/item.cc
    1.167 06/02/07 14:55:51 anozdrin@stripped +2 -2
    Updated according to the 5.1 data structures.

  mysql-test/r/trigger-grant.result
    1.5 06/02/07 14:55:51 anozdrin@stripped +3 -5
    Updated result file: use TRIGGER instead of SUPER for BUG#15166/15196 tests.

# 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:	anozdrin
# Host:	station.home
# Root:	/home/alik/Documents/AllProgs/MySQL/devel/5.2-tree

--- 1.166/sql/item.cc	2006-02-07 13:20:14 +03:00
+++ 1.167/sql/item.cc	2006-02-07 14:55:51 +03:00
@@ -5324,8 +5324,8 @@
       table_grants->want_privilege=
         access_type == AT_READ ? SELECT_ACL : UPDATE_ACL;
 
-      if (check_grant_column(thd, table_grants, triggers->table->s->db,
-                             triggers->table->s->table_name, field_name,
+      if (check_grant_column(thd, table_grants, triggers->table->s->db.str,
+                             triggers->table->s->table_name.str, field_name,
                              strlen(field_name), thd->security_ctx))
         return TRUE;
     }

--- 1.4/mysql-test/r/trigger-grant.result	2006-02-07 13:20:14 +03:00
+++ 1.5/mysql-test/r/trigger-grant.result	2006-02-07 14:55:51 +03:00
@@ -195,18 +195,16 @@
 CREATE TABLE t4(col CHAR(20));
 CREATE USER mysqltest_u1@localhost;
 REVOKE ALL PRIVILEGES, GRANT OPTION FROM mysqltest_u1@localhost;
-GRANT SUPER ON *.* TO mysqltest_u1@localhost;
-GRANT SELECT ON mysqltest_db1.t1 TO mysqltest_u1@localhost;
+GRANT TRIGGER ON mysqltest_db1.* TO mysqltest_u1@localhost;
 SET @mysqltest_var = NULL;
 
 ---> connection: default
 use mysqltest_db1;
-REVOKE SELECT ON mysqltest_db1.t1 FROM mysqltest_u1@localhost;
 GRANT DELETE ON mysqltest_db1.* TO mysqltest_u1@localhost;
 SHOW GRANTS FOR mysqltest_u1@localhost;
 Grants for mysqltest_u1@localhost
-GRANT SUPER ON *.* TO 'mysqltest_u1'@'localhost'
-GRANT DELETE ON `mysqltest_db1`.* TO 'mysqltest_u1'@'localhost'
+GRANT USAGE ON *.* TO 'mysqltest_u1'@'localhost'
+GRANT DELETE, TRIGGER ON `mysqltest_db1`.* TO 'mysqltest_u1'@'localhost'
 
 ---> connection: bug15166_u1_con
 use mysqltest_db1;

--- 1.45/sql/sql_trigger.cc	2006-02-07 13:38:40 +03:00
+++ 1.46/sql/sql_trigger.cc	2006-02-07 14:55:51 +03:00
@@ -1172,7 +1172,7 @@
 
     fill_effective_table_privileges(thd,
                                     &subject_table_grants[event][time_type],
-                                    table->s->db, table->s->table_name);
+                                    table->s->db.str, table->s->table_name.str);
 
     /* Check that the definer has TRIGGER privilege on the subject table. */
 
Thread
bk commit into 5.2 tree (anozdrin:1.2097) BUG#15166Alexander Nozdrin7 Feb