diff options
author | unknown <monty@hundin.mysql.fi> | 2002-05-15 18:41:36 +0300 |
---|---|---|
committer | unknown <monty@hundin.mysql.fi> | 2002-05-15 18:41:36 +0300 |
commit | dc2b6e456fb16685a4191537bf83e1161cb28d93 (patch) | |
tree | 5e1353fbc40fec5669ada6707abc2aa491ec80aa /libmysqld | |
parent | 68f972b5d470eed86347f0948fbf672d52ee1a5d (diff) | |
download | mariadb-git-dc2b6e456fb16685a4191537bf83e1161cb28d93.tar.gz |
Fixed some things to make MySQL to compile again.
libmysqld/lib_sql.cc:
Fix to make the embedded server compile with the new USER_REOSURCEs.
sql/sql_acl.cc:
Fixed wrong test in password checking.
sql/sql_cache.cc:
Fixed wrong cast
sql/sql_parse.cc:
Cleanup
Diffstat (limited to 'libmysqld')
-rw-r--r-- | libmysqld/lib_sql.cc | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/libmysqld/lib_sql.cc b/libmysqld/lib_sql.cc index 5b8df1d118d..1ef84607155 100644 --- a/libmysqld/lib_sql.cc +++ b/libmysqld/lib_sql.cc @@ -236,7 +236,7 @@ static bool check_user(THD *thd,enum_server_command command, const char *user, const char *passwd, const char *db, bool check_count) { NET *net= &thd->net; - uint max=0; + USER_RESOURCES ur; thd->db=0; if (!(thd->user = my_strdup(user, MYF(0)))) @@ -248,22 +248,22 @@ static bool check_user(THD *thd,enum_server_command command, const char *user, passwd, thd->scramble, &thd->priv_user, protocol_version == 9 || !(thd->client_capabilities & - CLIENT_LONG_PASSWORD),&max); - DBUG_PRINT("general", + CLIENT_LONG_PASSWORD),&ur); + DBUG_PRINT("info", ("Capabilities: %d packet_length: %d Host: '%s' User: '%s' Using password: %s Access: %u db: '%s'", thd->client_capabilities, thd->max_packet_length, - thd->host ? thd->host : thd->ip, thd->priv_user, + thd->host_or_ip, thd->priv_user, passwd[0] ? "yes": "no", thd->master_access, thd->db ? thd->db : "*none*")); if (thd->master_access & NO_ACCESS) { net_printf(net, ER_ACCESS_DENIED_ERROR, thd->user, - thd->host ? thd->host : thd->ip, + thd->host_or_ip, passwd[0] ? ER(ER_YES) : ER(ER_NO)); mysql_log.write(thd,COM_CONNECT,ER(ER_ACCESS_DENIED_ERROR), thd->user, - thd->host ? thd->host : thd->ip ? thd->ip : "unknown ip", + thd->host_or_ip, passwd[0] ? ER(ER_YES) : ER(ER_NO)); return(1); // Error already given } @@ -284,7 +284,7 @@ static bool check_user(THD *thd,enum_server_command command, const char *user, (char*) "%s@%s on %s" : (char*) "%s@%s as anonymous on %s"), user, - thd->host ? thd->host : thd->ip ? thd->ip : "unknown ip", + thd->host_or_ip, db ? db : (char*) ""); thd->db_access=0; if (db && db[0]) |