mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Fix for BUG#4678 "mysql-test-run fails on grant_cache":
do not use '' as user in tests, because it picks the Unix login (which gives unexpected results if it is 'root') (such behaviour is a feature of mysql_real_connect(), see the manual). mysql-test/t/grant_cache.test: do not use '' as user in tests, because it picks the Unix login (which gives unexpected results if it is 'root'). sql/slave.cc: a comment
This commit is contained in:
@@ -67,7 +67,8 @@ show status like "Qcache_queries_in_cache";
|
||||
show status like "Qcache_hits";
|
||||
show status like "Qcache_not_cached";
|
||||
|
||||
connect (unkuser,localhost,,,,$MASTER_MYPORT,master.sock);
|
||||
# Don't use '' as user because it will pick Unix login
|
||||
connect (unkuser,localhost,unkuser,,,$MASTER_MYPORT,master.sock);
|
||||
connection unkuser;
|
||||
show grants for current_user();
|
||||
|
||||
|
||||
@@ -1236,6 +1236,12 @@ not always make sense; please check the manual before using it).";
|
||||
/*
|
||||
Check that the master's global character_set_server and ours are the same.
|
||||
Not fatal if query fails (old master?).
|
||||
Note that we don't check for equality of global character_set_client and
|
||||
collation_connection (neither do we prevent their setting in
|
||||
set_var.cc). That's because from what I (Guilhem) have tested, the global
|
||||
values of these 2 are never used (new connections don't use them).
|
||||
We don't test equality of global collation_database either as it's is
|
||||
going to be deprecated (made read-only) in 4.1 very soon.
|
||||
*/
|
||||
if (!mysql_real_query(mysql, "SELECT @@GLOBAL.COLLATION_SERVER", 32) &&
|
||||
(master_res= mysql_store_result(mysql)))
|
||||
|
||||
Reference in New Issue
Block a user