diff options
author | unknown <monty@hundin.mysql.fi> | 2001-08-14 20:33:49 +0300 |
---|---|---|
committer | unknown <monty@hundin.mysql.fi> | 2001-08-14 20:33:49 +0300 |
commit | 410dd0779c32b1975eceeab92a1e62ff099f37db (patch) | |
tree | 63b1bcf87d376e768395f4a058416187ee0aad95 /sql/sql_acl.cc | |
parent | 97250b9c40a378659c6c4423461021231a3b551d (diff) | |
download | mariadb-git-410dd0779c32b1975eceeab92a1e62ff099f37db.tar.gz |
Remove warnings and portability fixes
New global read lock code
Fixed bug in DATETIME with WHERE optimization
Made UNION code more general.
include/global.h:
Remove warning on Linux Alpha
include/mysql_com.h:
Move some C variables inside extern "C" block.
include/mysqld_error.h:
New error mesages
myisam/mi_write.c:
cleanup
mysql-test/r/select.result:
Fix because of table lists now always has a database argument.
mysql-test/r/type_datetime.result:
Test for bug with datetime and where optimization
mysql-test/r/union.result:
Updated result
mysql-test/t/type_datetime.test:
New test for datetime
mysql-test/t/union.test:
More testing of error conditions
sql/item_sum.cc:
Remove warnings on Linux Alpha
sql/item_sum.h:
Cleanup
sql/lock.cc:
Cleaned up global lock handling
sql/log_event.cc:
Removed default arguments from declarations (not allowed in cxx)
sql/mysql_priv.h:
New prototypes
sql/mysqld.cc:
Fix for global locks
sql/opt_range.cc:
Cleanup
sql/share/czech/errmsg.txt:
New errors
sql/share/danish/errmsg.txt:
New errors
sql/share/dutch/errmsg.txt:
New errors
sql/share/english/errmsg.txt:
New errors
sql/share/estonian/errmsg.txt:
New errors
sql/share/french/errmsg.txt:
New errors
sql/share/german/errmsg.txt:
New errors
sql/share/greek/errmsg.txt:
New errors
sql/share/hungarian/errmsg.txt:
New errors
sql/share/italian/errmsg.txt:
New errors
sql/share/japanese/errmsg.txt:
New errors
sql/share/korean/errmsg.txt:
New errors
sql/share/norwegian-ny/errmsg.txt:
New errors
sql/share/norwegian/errmsg.txt:
New errors
sql/share/polish/errmsg.txt:
New errors
sql/share/portuguese/errmsg.txt:
New errors
sql/share/romanian/errmsg.txt:
New errors
sql/share/russian/errmsg.txt:
New errors
sql/share/slovak/errmsg.txt:
New errors
sql/share/spanish/errmsg.txt:
New errors
sql/share/swedish/errmsg.OLD:
New errors
sql/share/swedish/errmsg.txt:
New errors
sql/sql_acl.cc:
Use thd->host_or_ip
sql/sql_class.cc:
Use new global lock code
sql/sql_class.h:
host_or_ip
sql/sql_db.cc:
host_or_ip
sql/sql_delete.cc:
Use now global lock code
sql/sql_lex.h:
Cleanup of not used states and variables
sql/sql_parse.cc:
Use now global locks.
Made UNION code more general.
Change to use thd->hosts_or_ip.
TABLE_LIST now always has 'db' set.
sql/sql_repl.cc:
Portability fixes.
Changed wrong usage of my_vsnprintf -> my_snprintf
sql/sql_select.cc:
Changes for UNION
sql/sql_show.cc:
Cleanup
sql/sql_union.cc:
Handle 'select_result' outside of mysql_union().
sql/sql_yacc.yy:
Fixes for union
Diffstat (limited to 'sql/sql_acl.cc')
-rw-r--r-- | sql/sql_acl.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/sql/sql_acl.cc b/sql/sql_acl.cc index 5fc3d32b817..4adc93b7aa4 100644 --- a/sql/sql_acl.cc +++ b/sql/sql_acl.cc @@ -1006,7 +1006,7 @@ static int replace_user_table(TABLE *table, const LEX_USER &combo, my_printf_error(ER_NO_PERMISSION_TO_CREATE_USER, ER(ER_NO_PERMISSION_TO_CREATE_USER), MYF(0),thd->user, - thd->host ? thd->host : thd->ip ? thd->ip: ""); + thd->host_or_ip); error= -1; goto end; } @@ -1503,8 +1503,7 @@ static int replace_table_table(THD *thd, GRANT_TABLE *grant_table, uint store_table_rights,store_col_rights; DBUG_ENTER("replace_table_table"); - strxmov(grantor,thd->user,"@",thd->host ? thd->host : thd->ip ? thd->ip :"", - NullS); + strxmov(grantor, thd->user, "@", thd->host_or_ip, NullS); // The following should always succeed as new users are created before // this function is called! @@ -2091,7 +2090,7 @@ bool check_grant(THD *thd, uint want_access, TABLE_LIST *tables, net_printf(&thd->net,ER_TABLEACCESS_DENIED_ERROR, command, thd->priv_user, - thd->host ? thd->host : (thd->ip ? thd->ip : "unknown"), + thd->host_or_ip, table ? table->real_name : "unknown"); } return 1; @@ -2154,7 +2153,7 @@ bool check_grant_column (THD *thd,TABLE *table, const char *name, MYF(0), command, thd->priv_user, - thd->host ? thd->host : (thd->ip ? thd->ip : "unknown"), + thd->host_or_ip, name, table ? table->real_name : "unknown"); } @@ -2212,7 +2211,7 @@ bool check_grant_all_columns(THD *thd,uint want_access, TABLE *table) MYF(0), command, thd->priv_user, - thd->host ? thd->host : (thd->ip ? thd->ip : "unknown"), + thd->host_or_ip, field ? field->field_name : "unknown", table->real_name); return 1; |