diff options
author | monty@nosik.monty.fi <> | 2006-11-27 14:07:52 +0200 |
---|---|---|
committer | monty@nosik.monty.fi <> | 2006-11-27 14:07:52 +0200 |
commit | 313f23a93af801ca368fd5f3123f952ab2b8da68 (patch) | |
tree | 854da1ac89162145e99744fab50d0ea2da4045ed /sql/sql_parse.cc | |
parent | e394d254fb4c7d93279c55b7762898ddc0629dd3 (diff) | |
parent | becf45cd8e5195047a77379175cad4c154f04ada (diff) | |
download | mariadb-git-313f23a93af801ca368fd5f3123f952ab2b8da68.tar.gz |
Merge bk-internal.mysql.com:/home/bk/mysql-5.1-marvel
into mysql.com:/home/my/mysql-5.1
Diffstat (limited to 'sql/sql_parse.cc')
-rw-r--r-- | sql/sql_parse.cc | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index 6c21943774e..5d7fdcae3f7 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -394,9 +394,9 @@ int check_user(THD *thd, enum enum_server_command command, NO_ACCESS)) // authentication is OK { DBUG_PRINT("info", - ("Capabilities: %lx packet_length: %ld Host: '%s' " + ("Capabilities: %lu packet_length: %ld Host: '%s' " "Login user: '%s' Priv_user: '%s' Using password: %s " - "Access: %u db: '%s'", + "Access: %lu db: '%s'", thd->client_capabilities, thd->max_client_packet_length, thd->main_security_ctx.host_or_ip, @@ -1002,7 +1002,7 @@ static int check_connection(THD *thd) if (thd->client_capabilities & CLIENT_IGNORE_SPACE) thd->variables.sql_mode|= MODE_IGNORE_SPACE; #ifdef HAVE_OPENSSL - DBUG_PRINT("info", ("client capabilities: %d", thd->client_capabilities)); + DBUG_PRINT("info", ("client capabilities: %lu", thd->client_capabilities)); if (thd->client_capabilities & CLIENT_SSL) { /* Do the SSL layering. */ @@ -1161,7 +1161,7 @@ pthread_handler_t handle_one_connection(void *arg) of handle_one_connection, which is thd. We need to know the start of the stack so that we could check for stack overruns. */ - DBUG_PRINT("info", ("handle_one_connection called by thread %d\n", + DBUG_PRINT("info", ("handle_one_connection called by thread %lu\n", thd->thread_id)); /* now that we've called my_thread_init(), it is safe to call DBUG_* */ @@ -1616,7 +1616,7 @@ bool do_command(THD *thd) command= COM_END; // Wrong command DBUG_PRINT("info",("Command on %s = %d (%s)", vio_description(net->vio), command, - command_name[command])); + command_name[command].str)); } net->read_timeout=old_timeout; // restore it /* @@ -1851,7 +1851,9 @@ bool dispatch_command(enum enum_server_command command, THD *thd, if (alloc_query(thd, packet, packet_length)) break; // fatal error is set char *packet_end= thd->query + thd->query_length; - general_log_print(thd, command, "%.*b", thd->query_length, thd->query); + /* 'b' stands for 'buffer' parameter', special for 'my_snprintf' */ + const char *format= "%.*b"; + general_log_print(thd, command, format, thd->query_length, thd->query); DBUG_PRINT("query",("%-.4096s",thd->query)); if (!(specialflag & SPECIAL_NO_PRIOR)) |