Commit 6e501e65 authored by unknown's avatar unknown
Browse files

Fixed problems detected by pushbuild


mysql-test/t/log_state.test:
  Move disconnect last to avoid sporadic failures in test because 'Quit' command appeared in general log
plugin/daemon_example/daemon_example.c:
  Define __attribute__ to fix compiler error with not gcc compilers
sql-common/client.c:
  Fixed spelling error
sql/sql_parse.cc:
  Added comment
parent 721e4128
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -37,7 +37,6 @@ set session long_query_time=1;
select sleep(2);
--replace_column 1 TIMESTAMP 2 USER_HOST 3 QUERY_TIME
select * from mysql.slow_log;
disconnect con1;
connection default;
show global variables
where Variable_name = 'log' or Variable_name = 'log_slow_queries' or
@@ -121,3 +120,8 @@ drop table t1;
select * from mysql.general_log;

--enable_ps_protocol

#
# Cleanup (must be done last to avoid delayed 'Quit' message in general log)
#
disconnect con1;
+3 −3
Original line number Diff line number Diff line
@@ -19,11 +19,11 @@
#include <mysql/plugin.h>

/*
#if !defined(__attribute__) && (defined(__cplusplus) || !defined(__GNUC__)  || __GNUC__ == 2 && __GNUC_MINOR__ < 8)
  Disable __attribute__() on non-gcc compilers.
*/
#if !defined(__attribute__) && !defined(__GNUC__)
#define __attribute__(A)
#endif
*/



/*
+1 −1
Original line number Diff line number Diff line
@@ -682,7 +682,7 @@ cli_advanced_command(MYSQL *mysql, enum enum_server_command command,
  mysql->info=0;
  mysql->affected_rows= ~(my_ulonglong) 0;
  /*
    We don't want to clear the protocol buffer on COM_QUIT, beacsue if
    We don't want to clear the protocol buffer on COM_QUIT, because if
    the previous command was a shutdown command, we may have the
    response for the COM_QUIT already in the communication buffer
  */
+5 −1
Original line number Diff line number Diff line
@@ -413,7 +413,11 @@ int check_user(THD *thd, enum enum_server_command command,
        }
      }

      /* Why logging is performed before all checks've passed? */
      /*
        Log the command before authentication checks, so that the user can
        check the log for the tried login tried and also to detect
        break-in attempts.
      */
      general_log_print(thd, command,
                        (thd->main_security_ctx.priv_user ==
                         thd->main_security_ctx.user ?