Automatic merge with MariaDB trunk.

This commit is contained in:
unknown 2009-12-16 09:13:18 +01:00
commit 342f047b24
35 changed files with 448 additions and 288 deletions

View File

@ -1,6 +1,6 @@
cflags="$c_warnings $extra_flags" cflags="$c_warnings $extra_flags $EXTRA_FLAGS $EXTRA_CFLAGS"
cxxflags="$cxx_warnings $base_cxxflags $extra_flags" cxxflags="$cxx_warnings $base_cxxflags $extra_flags $EXTRA_FLAGS $EXTRA_CXXFLAGS"
extra_configs="$extra_configs $local_infile_configs" extra_configs="$extra_configs $local_infile_configs $EXTRA_CONFIGS"
configure="./configure $base_configs $extra_configs" configure="./configure $base_configs $extra_configs"
commands="\ commands="\

View File

@ -34,6 +34,14 @@ parse_options()
full_debug="=full";; full_debug="=full";;
--warning-mode=*) --warning-mode=*)
warning_mode=`get_key_value "$1"`;; warning_mode=`get_key_value "$1"`;;
--extra-flags=*)
EXTRA_FLAGS=`get_key_value "$1"`;;
--extra-cflags=*)
EXTRA_CFLAGS=`get_key_value "$1"`;;
--extra-cxxflags=*)
EXTRA_CXXFLAGS=`get_key_value "$1"`;;
--extra-configs=*)
EXTRA_CONFIGS=`get_key_value "$1"`;;
-c | --just-configure) -c | --just-configure)
just_configure=1;; just_configure=1;;
-n | --just-print | --print) -n | --just-print | --print)

View File

@ -1279,7 +1279,6 @@ sig_handler handle_sigint(int sig)
char kill_buffer[40]; char kill_buffer[40];
MYSQL *kill_mysql= NULL; MYSQL *kill_mysql= NULL;
/* terminate if no query being executed, or we already tried interrupting */
/* terminate if no query being executed, or we already tried interrupting */ /* terminate if no query being executed, or we already tried interrupting */
if (!executing_query || (interrupted_query == 2)) if (!executing_query || (interrupted_query == 2))
{ {
@ -1295,6 +1294,7 @@ sig_handler handle_sigint(int sig)
goto err; goto err;
} }
/* First time try to kill the query, second time the connection */
interrupted_query++; interrupted_query++;
/* mysqld < 5 does not understand KILL QUERY, skip to KILL CONNECTION */ /* mysqld < 5 does not understand KILL QUERY, skip to KILL CONNECTION */
@ -1305,10 +1305,13 @@ sig_handler handle_sigint(int sig)
sprintf(kill_buffer, "KILL %s%lu", sprintf(kill_buffer, "KILL %s%lu",
(interrupted_query == 1) ? "QUERY " : "", (interrupted_query == 1) ? "QUERY " : "",
mysql_thread_id(&mysql)); mysql_thread_id(&mysql));
tee_fprintf(stdout, "Ctrl-C -- sending \"%s\" to server ...\n", kill_buffer); if (verbose)
tee_fprintf(stdout, "Ctrl-C -- sending \"%s\" to server ...\n",
kill_buffer);
mysql_real_query(kill_mysql, kill_buffer, (uint) strlen(kill_buffer)); mysql_real_query(kill_mysql, kill_buffer, (uint) strlen(kill_buffer));
mysql_close(kill_mysql); mysql_close(kill_mysql);
tee_fprintf(stdout, "Ctrl-C -- query aborted.\n"); tee_fprintf(stdout, "Ctrl-C -- query killed. Continuing normally.\n");
interrupted_query= 0;
return; return;
@ -1321,7 +1324,6 @@ err:
handler called mysql_end(). handler called mysql_end().
*/ */
mysql_thread_end(); mysql_thread_end();
return;
#else #else
mysql_end(sig); mysql_end(sig);
#endif #endif
@ -2881,13 +2883,8 @@ com_help(String *buffer __attribute__((unused)),
return com_server_help(buffer,line,help_arg); return com_server_help(buffer,line,help_arg);
} }
put_info("\nFor information about MySQL products and services, visit:\n" put_info("\nGeneral information about MariaDB can be found at\n"
" http://www.mysql.com/\n" "http://askmonty.org/wiki/index.php/Manual:Contents\n", INFO_INFO);
"For developer information, including the MySQL Reference Manual, "
"visit:\n"
" http://dev.mysql.com/\n"
"To buy MySQL Enterprise support, training, or other products, visit:\n"
" https://shop.mysql.com/\n", INFO_INFO);
put_info("List of all MySQL commands:", INFO_INFO); put_info("List of all MySQL commands:", INFO_INFO);
if (!named_cmds) if (!named_cmds)
put_info("Note that all text commands must be first on line and end with ';'",INFO_INFO); put_info("Note that all text commands must be first on line and end with ';'",INFO_INFO);

View File

@ -857,7 +857,8 @@ int main(int argc, char **argv)
if (!opt_write_binlog) if (!opt_write_binlog)
{ {
if (disable_binlog()) { if (disable_binlog())
{
first_error= 1; first_error= 1;
goto end; goto end;
} }

View File

@ -472,11 +472,10 @@ void concurrency_loop(MYSQL *mysql, uint current, option_string *eptr)
if (commit_rate) if (commit_rate)
run_query(mysql, "SET AUTOCOMMIT=0", strlen("SET AUTOCOMMIT=0")); run_query(mysql, "SET AUTOCOMMIT=0", strlen("SET AUTOCOMMIT=0"));
if (pre_system) if (pre_system && (sysret= system(pre_system)) != 0)
if ((sysret= system(pre_system)) != 0) fprintf(stderr,
fprintf(stderr, "Warning: Execution of pre_system option returned %d.\n",
"Warning: Execution of pre_system option returned %d.\n", sysret);
sysret);
/* /*
Pre statements are always run after all other logic so they can Pre statements are always run after all other logic so they can
@ -490,11 +489,10 @@ void concurrency_loop(MYSQL *mysql, uint current, option_string *eptr)
if (post_statements) if (post_statements)
run_statements(mysql, post_statements); run_statements(mysql, post_statements);
if (post_system) if (post_system && (sysret= system(post_system)) != 0)
if ((sysret= system(post_system)) != 0) fprintf(stderr,
fprintf(stderr, "Warning: Execution of post_system option returned %d.\n",
"Warning: Execution of post_system option returned %d.\n", sysret);
sysret);
/* We are finished with this run */ /* We are finished with this run */
if (auto_generate_sql_autoincrement || auto_generate_sql_guid_primary) if (auto_generate_sql_autoincrement || auto_generate_sql_guid_primary)
drop_primary_key_list(); drop_primary_key_list();

View File

@ -3497,9 +3497,10 @@ void do_diff_files(struct st_command *command)
if ((error= compare_files(ds_filename.str, ds_filename2.str)) && if ((error= compare_files(ds_filename.str, ds_filename2.str)) &&
match_expected_error(command, error, NULL) < 0) match_expected_error(command, error, NULL) < 0)
{ {
/* Compare of the two files failed, append them to output /*
so the failure can be analyzed, but only if it was not Compare of the two files failed, append them to output
expected to fail. so the failure can be analyzed, but only if it was not
expected to fail.
*/ */
show_diff(&ds_res, ds_filename.str, ds_filename2.str); show_diff(&ds_res, ds_filename.str, ds_filename2.str);
log_file.write(&ds_res); log_file.write(&ds_res);
@ -5013,7 +5014,8 @@ void do_connect(struct st_command *command)
con_options= ds_options.str; con_options= ds_options.str;
while (*con_options) while (*con_options)
{ {
char* end; size_t length;
char *end;
/* Step past any spaces in beginning of option*/ /* Step past any spaces in beginning of option*/
while (*con_options && my_isspace(charset_info, *con_options)) while (*con_options && my_isspace(charset_info, *con_options))
con_options++; con_options++;
@ -5021,13 +5023,14 @@ void do_connect(struct st_command *command)
end= con_options; end= con_options;
while (*end && !my_isspace(charset_info, *end)) while (*end && !my_isspace(charset_info, *end))
end++; end++;
if (!strncmp(con_options, "SSL", 3)) length= (size_t) (end - con_options);
if (length == 3 && !strncmp(con_options, "SSL", 3))
con_ssl= 1; con_ssl= 1;
else if (!strncmp(con_options, "COMPRESS", 8)) else if (length == 8 && !strncmp(con_options, "COMPRESS", 8))
con_compress= 1; con_compress= 1;
else if (!strncmp(con_options, "PIPE", 4)) else if (length == 4 && !strncmp(con_options, "PIPE", 4))
con_pipe= 1; con_pipe= 1;
else if (!strncmp(con_options, "SHM", 3)) else if (length == 3 && !strncmp(con_options, "SHM", 3))
con_shm= 1; con_shm= 1;
else else
die("Illegal option to connect: %.*s", die("Illegal option to connect: %.*s",
@ -5096,14 +5099,13 @@ void do_connect(struct st_command *command)
mysql_options(&con_slot->mysql, MYSQL_SHARED_MEMORY_BASE_NAME, ds_shm.str); mysql_options(&con_slot->mysql, MYSQL_SHARED_MEMORY_BASE_NAME, ds_shm.str);
mysql_options(&con_slot->mysql, MYSQL_OPT_PROTOCOL, &protocol); mysql_options(&con_slot->mysql, MYSQL_OPT_PROTOCOL, &protocol);
} }
else if(shared_memory_base_name) else if (shared_memory_base_name)
{ {
mysql_options(&con_slot->mysql, MYSQL_SHARED_MEMORY_BASE_NAME, mysql_options(&con_slot->mysql, MYSQL_SHARED_MEMORY_BASE_NAME,
shared_memory_base_name); shared_memory_base_name);
} }
#endif #endif
/* Use default db name */ /* Use default db name */
if (ds_database.length == 0) if (ds_database.length == 0)
dynstr_set(&ds_database, opt_db); dynstr_set(&ds_database, opt_db);
@ -6879,10 +6881,8 @@ void run_query_stmt(MYSQL *mysql, struct st_command *command,
MYSQL_STMT *stmt; MYSQL_STMT *stmt;
DYNAMIC_STRING ds_prepare_warnings; DYNAMIC_STRING ds_prepare_warnings;
DYNAMIC_STRING ds_execute_warnings; DYNAMIC_STRING ds_execute_warnings;
ulonglong affected_rows;
DBUG_ENTER("run_query_stmt"); DBUG_ENTER("run_query_stmt");
DBUG_PRINT("query", ("'%-.60s'", query)); DBUG_PRINT("query", ("'%-.60s'", query));
LINT_INIT(affected_rows);
/* /*
Init a new stmt if it's not already one created for this connection Init a new stmt if it's not already one created for this connection
@ -6981,6 +6981,9 @@ void run_query_stmt(MYSQL *mysql, struct st_command *command,
handle_no_error(command); handle_no_error(command);
if (!disable_result_log) if (!disable_result_log)
{ {
ulonglong affected_rows;
LINT_INIT(affected_rows);
/* /*
Not all statements creates a result set. If there is one we can Not all statements creates a result set. If there is one we can
now create another normal result set that contains the meta now create another normal result set that contains the meta
@ -7026,39 +7029,33 @@ void run_query_stmt(MYSQL *mysql, struct st_command *command,
Need to grab affected rows information before getting Need to grab affected rows information before getting
warnings here warnings here
*/ */
if (!disable_info)
affected_rows= mysql_affected_rows(mysql);
if (!disable_warnings)
{ {
ulonglong affected_rows; /* Get the warnings from execute */
LINT_INIT(affected_rows);
if (!disable_info) /* Append warnings to ds - if there are any */
affected_rows= mysql_affected_rows(mysql); if (append_warnings(&ds_execute_warnings, mysql) ||
ds_execute_warnings.length ||
if (!disable_warnings) ds_prepare_warnings.length ||
ds_warnings->length)
{ {
/* Get the warnings from execute */ dynstr_append_mem(ds, "Warnings:\n", 10);
if (ds_warnings->length)
/* Append warnings to ds - if there are any */ dynstr_append_mem(ds, ds_warnings->str,
if (append_warnings(&ds_execute_warnings, mysql) || ds_warnings->length);
ds_execute_warnings.length || if (ds_prepare_warnings.length)
ds_prepare_warnings.length || dynstr_append_mem(ds, ds_prepare_warnings.str,
ds_warnings->length) ds_prepare_warnings.length);
{ if (ds_execute_warnings.length)
dynstr_append_mem(ds, "Warnings:\n", 10); dynstr_append_mem(ds, ds_execute_warnings.str,
if (ds_warnings->length) ds_execute_warnings.length);
dynstr_append_mem(ds, ds_warnings->str,
ds_warnings->length);
if (ds_prepare_warnings.length)
dynstr_append_mem(ds, ds_prepare_warnings.str,
ds_prepare_warnings.length);
if (ds_execute_warnings.length)
dynstr_append_mem(ds, ds_execute_warnings.str,
ds_execute_warnings.length);
}
} }
if (!disable_info)
append_info(ds, affected_rows, mysql_info(mysql));
} }
if (!disable_info)
append_info(ds, affected_rows, mysql_info(mysql));
} }
end: end:
@ -7235,7 +7232,6 @@ void run_query(struct st_connection *cn, struct st_command *command, int flags)
} }
dynstr_free(&query_str); dynstr_free(&query_str);
} }
if (sp_protocol_enabled && if (sp_protocol_enabled &&
@ -7662,6 +7658,7 @@ int main(int argc, char **argv)
my_bool q_send_flag= 0, abort_flag= 0; my_bool q_send_flag= 0, abort_flag= 0;
uint command_executed= 0, last_command_executed= 0; uint command_executed= 0, last_command_executed= 0;
char save_file[FN_REFLEN]; char save_file[FN_REFLEN];
bool empty_result= FALSE;
MY_INIT(argv[0]); MY_INIT(argv[0]);
save_file[0]= 0; save_file[0]= 0;
@ -7819,6 +7816,7 @@ int main(int argc, char **argv)
verbose_msg("Start processing test commands from '%s' ...", cur_file->file_name); verbose_msg("Start processing test commands from '%s' ...", cur_file->file_name);
while (!read_command(&command) && !abort_flag) while (!read_command(&command) && !abort_flag)
{ {
my_bool ok_to_do;
int current_line_inc = 1, processed = 0; int current_line_inc = 1, processed = 0;
if (command->type == Q_UNKNOWN || command->type == Q_COMMENT_WITH_COMMAND) if (command->type == Q_UNKNOWN || command->type == Q_COMMENT_WITH_COMMAND)
get_command_type(command); get_command_type(command);
@ -7831,7 +7829,7 @@ int main(int argc, char **argv)
command->type= Q_COMMENT; command->type= Q_COMMENT;
} }
my_bool ok_to_do= cur_block->ok; ok_to_do= cur_block->ok;
/* /*
Some commands need to be "done" the first time if they may get Some commands need to be "done" the first time if they may get
re-iterated over in a true context. This can only happen if there's re-iterated over in a true context. This can only happen if there's
@ -8167,8 +8165,6 @@ int main(int argc, char **argv)
if (parsing_disabled) if (parsing_disabled)
die("Test ended with parsing disabled"); die("Test ended with parsing disabled");
my_bool empty_result= FALSE;
/* /*
The whole test has been executed _sucessfully_. The whole test has been executed _sucessfully_.
Time to compare result or save it to record file. Time to compare result or save it to record file.

View File

@ -497,12 +497,18 @@ int DbugParse(CODE_STATE *cs, const char *control)
const char *end; const char *end;
int rel, f_used=0; int rel, f_used=0;
struct settings *stack; struct settings *stack;
int org_cs_locked;
stack= cs->stack; stack= cs->stack;
if (!(org_cs_locked= cs->locked))
{
cs->locked= 1;
pthread_mutex_lock(&THR_LOCK_dbug);
}
if (control[0] == '-' && control[1] == '#') if (control[0] == '-' && control[1] == '#')
control+=2; control+=2;
rel= control[0] == '+' || control[0] == '-'; rel= control[0] == '+' || control[0] == '-';
if ((!rel || (!stack->out_file && !stack->next))) if ((!rel || (!stack->out_file && !stack->next)))
{ {
@ -550,9 +556,11 @@ int DbugParse(CODE_STATE *cs, const char *control)
while (control < end) while (control < end)
{ {
int c, sign= (*control == '+') ? 1 : (*control == '-') ? -1 : 0; int c, sign= (*control == '+') ? 1 : (*control == '-') ? -1 : 0;
if (sign) control++; if (sign)
control++;
c= *control++; c= *control++;
if (*control == ',') control++; if (*control == ',')
control++;
/* XXX when adding new cases here, don't forget _db_explain_ ! */ /* XXX when adding new cases here, don't forget _db_explain_ ! */
switch (c) { switch (c) {
case 'd': case 'd':
@ -570,7 +578,7 @@ int DbugParse(CODE_STATE *cs, const char *control)
{ {
if (DEBUGGING) if (DEBUGGING)
stack->keywords= ListDel(stack->keywords, control, end); stack->keywords= ListDel(stack->keywords, control, end);
break; break;
} }
stack->keywords= ListAdd(stack->keywords, control, end); stack->keywords= ListAdd(stack->keywords, control, end);
stack->flags |= DEBUG_ON; stack->flags |= DEBUG_ON;
@ -718,8 +726,13 @@ int DbugParse(CODE_STATE *cs, const char *control)
control=end+1; control=end+1;
end= DbugStrTok(control); end= DbugStrTok(control);
} }
return !rel || f_used; if (!org_cs_locked)
} {
pthread_mutex_unlock(&THR_LOCK_dbug);
cs->locked= 0;
}
return !rel || f_used;}
#define framep_trace_flag(cs, frp) (frp ? \ #define framep_trace_flag(cs, frp) (frp ? \
frp->level & TRACE_ON : \ frp->level & TRACE_ON : \
@ -1340,11 +1353,11 @@ void _db_doprnt_(const char *format,...)
va_start(args,format); va_start(args,format);
if (!cs->locked)
pthread_mutex_lock(&THR_LOCK_dbug);
if (_db_keyword_(cs, cs->u_keyword, 0)) if (_db_keyword_(cs, cs->u_keyword, 0))
{ {
int save_errno=errno; int save_errno=errno;
if (!cs->locked)
pthread_mutex_lock(&THR_LOCK_dbug);
DoPrefix(cs, cs->u_line); DoPrefix(cs, cs->u_line);
if (TRACING) if (TRACING)
Indent(cs, cs->level + 1); Indent(cs, cs->level + 1);
@ -1356,6 +1369,9 @@ void _db_doprnt_(const char *format,...)
DbugFlush(cs); DbugFlush(cs);
errno=save_errno; errno=save_errno;
} }
else if (!cs->locked)
pthread_mutex_unlock(&THR_LOCK_dbug);
va_end(args); va_end(args);
} }
@ -1386,10 +1402,10 @@ void _db_dump_(uint _line_, const char *keyword,
CODE_STATE *cs; CODE_STATE *cs;
get_code_state_or_return; get_code_state_or_return;
if (!cs->locked)
pthread_mutex_lock(&THR_LOCK_dbug);
if (_db_keyword_(cs, keyword, 0)) if (_db_keyword_(cs, keyword, 0))
{ {
if (!cs->locked)
pthread_mutex_lock(&THR_LOCK_dbug);
DoPrefix(cs, _line_); DoPrefix(cs, _line_);
if (TRACING) if (TRACING)
{ {
@ -1420,6 +1436,8 @@ void _db_dump_(uint _line_, const char *keyword,
(void) fputc('\n',cs->stack->out_file); (void) fputc('\n',cs->stack->out_file);
DbugFlush(cs); DbugFlush(cs);
} }
else if (!cs->locked)
pthread_mutex_unlock(&THR_LOCK_dbug);
} }
@ -2105,7 +2123,8 @@ static void DBUGCloseFile(CODE_STATE *cs, FILE *fp)
{ {
if (fp != stderr && fp != stdout && fclose(fp) == EOF) if (fp != stderr && fp != stdout && fclose(fp) == EOF)
{ {
pthread_mutex_lock(&THR_LOCK_dbug); if (!cs->locked)
pthread_mutex_lock(&THR_LOCK_dbug);
(void) fprintf(cs->stack->out_file, ERR_CLOSE, cs->process); (void) fprintf(cs->stack->out_file, ERR_CLOSE, cs->process);
perror(""); perror("");
DbugFlush(cs); DbugFlush(cs);

View File

@ -167,7 +167,8 @@ public:
void CleanNew(word32 newSize) void CleanNew(word32 newSize)
{ {
New(newSize); New(newSize);
memset(buffer_, 0, sz_ * sizeof(T)); if (sz_ > 0)
memset(buffer_, 0, sz_ * sizeof(T));
} }
void New(word32 newSize) void New(word32 newSize)

View File

@ -101,7 +101,6 @@ sub init_pattern {
sub collect_test_cases ($$) { sub collect_test_cases ($$) {
my $suites= shift; # Semicolon separated list of test suites my $suites= shift; # Semicolon separated list of test suites
my %found_suites;
my $opt_cases= shift; my $opt_cases= shift;
my $cases= []; # Array of hash(one hash for each testcase) my $cases= []; # Array of hash(one hash for each testcase)
@ -115,7 +114,6 @@ sub collect_test_cases ($$) {
["ha_innodb_plugin.dll", "ha_innodb_plugin.so", ["ha_innodb_plugin.dll", "ha_innodb_plugin.so",
"ha_innodb_plugin.sl"], "ha_innodb_plugin.sl"],
NOT_REQUIRED); NOT_REQUIRED);
$do_innodb_plugin= ($::mysql_version_id >= 50100 && $do_innodb_plugin= ($::mysql_version_id >= 50100 &&
!(IS_WINDOWS && $::opt_embedded_server) && !(IS_WINDOWS && $::opt_embedded_server) &&
$lib_innodb_plugin); $lib_innodb_plugin);
@ -123,7 +121,6 @@ sub collect_test_cases ($$) {
foreach my $suite (split(",", $suites)) foreach my $suite (split(",", $suites))
{ {
push(@$cases, collect_one_suite($suite, $opt_cases)); push(@$cases, collect_one_suite($suite, $opt_cases));
$found_suites{$suite}= 1;
last if $some_test_found; last if $some_test_found;
} }
@ -136,12 +133,6 @@ sub collect_test_cases ($$) {
{ {
my $found= 0; my $found= 0;
my ($sname, $tname, $extension)= split_testname($test_name_spec); my ($sname, $tname, $extension)= split_testname($test_name_spec);
if (defined($sname) && !defined($found_suites{$sname}))
{
$found_suites{$sname}= 1;
push(@$cases, collect_one_suite($sname));
}
foreach my $test ( @$cases ) foreach my $test ( @$cases )
{ {
# test->{name} is always in suite.name format # test->{name} is always in suite.name format
@ -247,7 +238,7 @@ sub split_testname {
} }
sub collect_one_suite($) sub collect_one_suite
{ {
my $suite= shift; # Test suite name my $suite= shift; # Test suite name
my $opt_cases= shift; my $opt_cases= shift;
@ -767,7 +758,6 @@ sub process_opts_file {
} }
} }
############################################################################## ##############################################################################
# #
# Collect information about a single test case # Collect information about a single test case

View File

@ -388,7 +388,7 @@ MSG
} }
elsif (@$extra_warnings) elsif (@$extra_warnings)
{ {
mtr_error("There were errors/warnings in server logs after running test cases."); mtr_error("There where errors/warnings in server logs after running test cases.");
} }
elsif ($fail) elsif ($fail)
{ {

View File

@ -178,6 +178,7 @@ our @opt_extra_mysqltest_opt;
our $opt_compress; our $opt_compress;
our $opt_ssl; our $opt_ssl;
our $opt_skip_ssl;
our $opt_ssl_supported; our $opt_ssl_supported;
our $opt_ps_protocol; our $opt_ps_protocol;
our $opt_sp_protocol; our $opt_sp_protocol;

View File

@ -201,10 +201,10 @@ my $opt_mark_progress;
my $opt_sleep; my $opt_sleep;
my $opt_testcase_timeout= 15; # minutes my $opt_testcase_timeout= 15; # 15 minutes
my $opt_suite_timeout = 300; # minutes my $opt_suite_timeout = 360; # 6 hours
my $opt_shutdown_timeout= 10; # seconds my $opt_shutdown_timeout= 10; # 10 seconds
my $opt_start_timeout = 180; # seconds my $opt_start_timeout = 180; # 180 seconds
sub testcase_timeout { return $opt_testcase_timeout * 60; }; sub testcase_timeout { return $opt_testcase_timeout * 60; };
sub suite_timeout { return $opt_suite_timeout * 60; }; sub suite_timeout { return $opt_suite_timeout * 60; };
@ -1319,6 +1319,8 @@ sub command_line_setup {
{ {
# Indicate that we are using debugger # Indicate that we are using debugger
$glob_debugger= 1; $glob_debugger= 1;
$opt_testcase_timeout= 60*60*24; # Don't abort debugging with timeout
$opt_suite_timeout= $opt_testcase_timeout;
$opt_retry= 1; $opt_retry= 1;
$opt_retry_failure= 1; $opt_retry_failure= 1;
@ -2151,7 +2153,6 @@ sub environment_setup {
# Create an environment variable to make it possible # Create an environment variable to make it possible
# to detect that valgrind is being used from test cases # to detect that valgrind is being used from test cases
$ENV{'VALGRIND_TEST'}= $opt_valgrind; $ENV{'VALGRIND_TEST'}= $opt_valgrind;
} }
@ -2908,8 +2909,8 @@ sub mysql_install_db {
my $bootstrap_sql_file= "$opt_vardir/tmp/bootstrap.sql"; my $bootstrap_sql_file= "$opt_vardir/tmp/bootstrap.sql";
my $path_sql= my_find_file($install_basedir, my $path_sql= my_find_file($install_basedir,
["mysql", "sql/share", "share/mysql", ["mysql", "sql/share", "share/mariadb",
"share/mariadb", "share", "scripts"], "share/mysql", "share", "scripts"],
"mysql_system_tables.sql", "mysql_system_tables.sql",
NOT_REQUIRED); NOT_REQUIRED);
@ -3861,7 +3862,7 @@ sub extract_server_log ($$) {
my ($error_log, $tname) = @_; my ($error_log, $tname) = @_;
# Open the servers .err log file and read all lines # Open the servers .err log file and read all lines
# belonging to current tets into @lines # belonging to current test into @lines
my $Ferr = IO::File->new($error_log) my $Ferr = IO::File->new($error_log)
or mtr_error("Could not open file '$error_log' for reading: $!"); or mtr_error("Could not open file '$error_log' for reading: $!");
@ -5682,12 +5683,15 @@ Misc options
servers to exit before finishing the process servers to exit before finishing the process
fast Run as fast as possible, dont't wait for servers fast Run as fast as possible, dont't wait for servers
to shutdown etc. to shutdown etc.
parallel=N Run tests in N parallel threads (default=1) parallel=N Run tests in N parallel threads (default 1)
Use parallel=auto for auto-setting of N Use parallel=auto for auto-setting of N
repeat=N Run each test N number of times repeat=N Run each test N number of times
retry=N Retry tests that fail N times, limit number of failures retry=N Retry tests that fail up to N times (default $opt_retry).
to $opt_retry_failure Retries are also limited by the maximum number of
retry-failure=N Limit number of retries for a failed test failures before stopping, set with the --retry-failure
option
retry-failure=N When using the --retry option to retry failed tests,
stop when N failures have occured (default $opt_retry_failure)
reorder Reorder tests to get fewer server restarts reorder Reorder tests to get fewer server restarts
help Get this help text help Get this help text

View File

@ -1211,3 +1211,47 @@ HEX(DAYNAME(19700101))
0427043504420432043504400433 0427043504420432043504400433
SET character_set_connection=latin1; SET character_set_connection=latin1;
End of 5.0 tests End of 5.0 tests
Start of 5.1 tests
SET NAMES utf8;
CREATE TABLE t1 (
a varchar(10) CHARACTER SET ucs2 COLLATE ucs2_czech_ci,
key(a)
);
INSERT INTO t1 VALUES
('aa'),('bb'),('cc'),('dd'),('ee'),('ff'),('gg'),('hh'),('ii'),
('jj'),('kk'),('ll'),('mm'),('nn'),('oo'),('pp'),('rr'),('ss'),
('tt'),('uu'),('vv'),('ww'),('xx'),('yy'),('zz');
INSERT INTO t1 VALUES ('ca'),('cz'),('ch');
INSERT INTO t1 VALUES ('da'),('dz'), (X'0064017E');
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'b%';
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range a a 23 NULL 1 Using where; Using index
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'c%';
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range a a 23 NULL 30 Using where; Using index
SELECT * FROM t1 WHERE a LIKE 'c%';
a
ca
cc
cz
ch
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'ch%';
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range a a 23 NULL 1 Using where; Using index
SELECT * FROM t1 WHERE a LIKE 'ch%';
a
ch
ALTER TABLE t1 MODIFY a VARCHAR(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci;
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'd%';
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range a a 23 NULL 1 Using where; Using index
SELECT hex(concat('d',_ucs2 0x017E,'%'));
hex(concat('d',_ucs2 0x017E,'%'))
0064017E0025
EXPLAIN SELECT * FROM t1 WHERE a LIKE concat('d',_ucs2 0x017E,'%');
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range a a 23 NULL 1 Using where; Using index
SELECT hex(a) FROM t1 WHERE a LIKE concat('D',_ucs2 0x017E,'%');
hex(a)
0064017E
DROP TABLE t1;

View File

@ -319,3 +319,17 @@ SHOW ERRORS;
Level Code Message Level Code Message
Error 1051 Unknown table 't1' Error 1051 Unknown table 't1'
End of 5.0 tests End of 5.0 tests
set sql_mode = default;
select CAST(a AS DECIMAL(13,5)) FROM (SELECT '' as a) t;
CAST(a AS DECIMAL(13,5))
0.00000
Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ''
create table t1 (a integer unsigned);
insert into t1 values (1),(-1),(0),(-2);
Warnings:
Warning 1264 Out of range value for column 'a' at row 2
Warning 1264 Out of range value for column 'a' at row 4
drop table t1;
End of 5.1 tests

View File

@ -9,5 +9,4 @@
# Do not use any TAB characters for whitespace. # Do not use any TAB characters for whitespace.
# #
############################################################################## ##############################################################################
federated_server : needs fixup

View File

@ -175,6 +175,8 @@ CREATE TABLE db_bogus.t1 (
) )
; ;
INSERT INTO db_bogus.t1 VALUES ('2','this is bogus'); INSERT INTO db_bogus.t1 VALUES ('2','this is bogus');
create user test_fed@localhost identified by 'foo';
grant all on db_legitimate.* to test_fed@localhost;
create server 's1' foreign data wrapper 'mysql' options create server 's1' foreign data wrapper 'mysql' options
(HOST '127.0.0.1', (HOST '127.0.0.1',
DATABASE 'db_legitimate', DATABASE 'db_legitimate',
@ -211,15 +213,14 @@ id name
alter server s1 options (database 'db_bogus'); alter server s1 options (database 'db_bogus');
flush tables; flush tables;
select * from federated.t1; select * from federated.t1;
id name ERROR HY000: There was a problem processing the query on the foreign data source. Data source error: : 1044 : Access denied for user 'test_fed'@'localhost' to databa
2 this is bogus
drop server if exists 's1'; drop server if exists 's1';
ERROR 42000: Access denied; you need the SUPER privilege for this operation ERROR 42000: Access denied; you need the SUPER privilege for this operation
create server 's1' foreign data wrapper 'mysql' options create server 's1' foreign data wrapper 'mysql' options
(HOST '127.0.0.1', (HOST '127.0.0.1',
DATABASE 'db_legitimate', DATABASE 'db_legitimate',
USER 'root', USER 'test_fed',
PASSWORD '', PASSWORD 'foo',
PORT SLAVE_PORT, PORT SLAVE_PORT,
SOCKET '', SOCKET '',
OWNER 'root'); OWNER 'root');
@ -228,8 +229,8 @@ drop server 's1';
create server 's1' foreign data wrapper 'mysql' options create server 's1' foreign data wrapper 'mysql' options
(HOST '127.0.0.1', (HOST '127.0.0.1',
DATABASE 'db_legitimate', DATABASE 'db_legitimate',
USER 'root', USER 'test_fed',
PASSWORD '', PASSWORD 'foo',
PORT SLAVE_PORT, PORT SLAVE_PORT,
SOCKET '', SOCKET '',
OWNER 'root'); OWNER 'root');
@ -237,6 +238,7 @@ flush tables;
select * from federated.t1; select * from federated.t1;
id name id name
1 this is legitimate 1 this is legitimate
drop user test_fed@localhost;
drop database db_legitimate; drop database db_legitimate;
drop database db_bogus; drop database db_bogus;
drop user guest_super@localhost; drop user guest_super@localhost;
@ -275,6 +277,6 @@ call p1();
drop procedure p1; drop procedure p1;
drop server if exists s; drop server if exists s;
DROP TABLE IF EXISTS federated.t1; DROP TABLE IF EXISTS federated.t1;
DROP DATABASE federated; DROP DATABASE IF EXISTS federated;
DROP TABLE IF EXISTS federated.t1; DROP TABLE IF EXISTS federated.t1;
DROP DATABASE federated; DROP DATABASE IF EXISTS federated;

View File

@ -239,6 +239,7 @@ alter server s1 options (database 'db_bogus');
connection master; connection master;
flush tables; flush tables;
--error ER_QUERY_ON_FOREIGN_DATA_SOURCE
select * from federated.t1; select * from federated.t1;
connection conn_select; connection conn_select;
@ -249,8 +250,8 @@ drop server if exists 's1';
eval create server 's1' foreign data wrapper 'mysql' options eval create server 's1' foreign data wrapper 'mysql' options
(HOST '127.0.0.1', (HOST '127.0.0.1',
DATABASE 'db_legitimate', DATABASE 'db_legitimate',
USER 'root', USER 'test_fed',
PASSWORD '', PASSWORD 'foo',
PORT $SLAVE_MYPORT, PORT $SLAVE_MYPORT,
SOCKET '', SOCKET '',
OWNER 'root'); OWNER 'root');
@ -261,8 +262,8 @@ drop server 's1';
eval create server 's1' foreign data wrapper 'mysql' options eval create server 's1' foreign data wrapper 'mysql' options
(HOST '127.0.0.1', (HOST '127.0.0.1',
DATABASE 'db_legitimate', DATABASE 'db_legitimate',
USER 'root', USER 'test_fed',
PASSWORD '', PASSWORD 'foo',
PORT $SLAVE_MYPORT, PORT $SLAVE_MYPORT,
SOCKET '', SOCKET '',
OWNER 'root'); OWNER 'root');
@ -273,6 +274,7 @@ select * from federated.t1;
# clean up test # clean up test
connection slave; connection slave;
drop user test_fed@localhost;
drop database db_legitimate; drop database db_legitimate;
drop database db_bogus; drop database db_bogus;

View File

@ -3372,9 +3372,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 29 -3333.33 -3333.3333 29
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varbinary_1000` as decimal(37,2)) AS `CAST(my_varbinary_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varbinary_1000` AS `my_varbinary_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varbinary_1000` as decimal(37,2)) AS `CAST(my_varbinary_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varbinary_1000` AS `my_varbinary_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci
@ -3389,9 +3389,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 29 -3333.33 -3333.3333 29
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
DROP VIEW v1; DROP VIEW v1;
@ -3408,11 +3408,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 28 -3333.33 -3333.3333 28
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: ''
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
Warning 1292 Truncated incorrect DECIMAL value: '-1' Warning 1292 Truncated incorrect DECIMAL value: '-1'
Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333' Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333'
@ -3430,11 +3430,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 28 -3333.33 -3333.3333 28
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: ''
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
Warning 1292 Truncated incorrect DECIMAL value: '-1' Warning 1292 Truncated incorrect DECIMAL value: '-1'
Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333' Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333'
@ -3454,9 +3454,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 27 -3333.33 -3333.3333 27
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varchar_1000` as decimal(37,2)) AS `CAST(my_varchar_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varchar_1000` AS `my_varchar_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varchar_1000` as decimal(37,2)) AS `CAST(my_varchar_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varchar_1000` AS `my_varchar_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci
@ -3471,9 +3471,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 27 -3333.33 -3333.3333 27
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
DROP VIEW v1; DROP VIEW v1;
@ -3490,11 +3490,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 26 -3333.33 -3333.3333 26
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ' Warning 1292 Truncated incorrect DECIMAL value: ' '
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
@ -3510,11 +3510,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 26 -3333.33 -3333.3333 26
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ' Warning 1292 Truncated incorrect DECIMAL value: ' '
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
DROP VIEW v1; DROP VIEW v1;

View File

@ -3373,9 +3373,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 29 -3333.33 -3333.3333 29
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varbinary_1000` as decimal(37,2)) AS `CAST(my_varbinary_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varbinary_1000` AS `my_varbinary_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varbinary_1000` as decimal(37,2)) AS `CAST(my_varbinary_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varbinary_1000` AS `my_varbinary_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci
@ -3390,9 +3390,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 29 -3333.33 -3333.3333 29
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
DROP VIEW v1; DROP VIEW v1;
@ -3409,11 +3409,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 28 -3333.33 -3333.3333 28
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: ''
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
Warning 1292 Truncated incorrect DECIMAL value: '-1' Warning 1292 Truncated incorrect DECIMAL value: '-1'
Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333' Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333'
@ -3431,11 +3431,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 28 -3333.33 -3333.3333 28
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: ''
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
Warning 1292 Truncated incorrect DECIMAL value: '-1' Warning 1292 Truncated incorrect DECIMAL value: '-1'
Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333' Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333'
@ -3455,9 +3455,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 27 -3333.33 -3333.3333 27
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varchar_1000` as decimal(37,2)) AS `CAST(my_varchar_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varchar_1000` AS `my_varchar_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varchar_1000` as decimal(37,2)) AS `CAST(my_varchar_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varchar_1000` AS `my_varchar_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci
@ -3472,9 +3472,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 27 -3333.33 -3333.3333 27
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
DROP VIEW v1; DROP VIEW v1;
@ -3491,11 +3491,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 26 -3333.33 -3333.3333 26
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ' Warning 1292 Truncated incorrect DECIMAL value: ' '
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
@ -3511,11 +3511,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 26 -3333.33 -3333.3333 26
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ' Warning 1292 Truncated incorrect DECIMAL value: ' '
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
DROP VIEW v1; DROP VIEW v1;

View File

@ -3373,9 +3373,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 29 -3333.33 -3333.3333 29
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varbinary_1000` as decimal(37,2)) AS `CAST(my_varbinary_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varbinary_1000` AS `my_varbinary_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varbinary_1000` as decimal(37,2)) AS `CAST(my_varbinary_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varbinary_1000` AS `my_varbinary_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci
@ -3390,9 +3390,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 29 -3333.33 -3333.3333 29
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
DROP VIEW v1; DROP VIEW v1;
@ -3409,11 +3409,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 28 -3333.33 -3333.3333 28
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: ''
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
Warning 1292 Truncated incorrect DECIMAL value: '-1' Warning 1292 Truncated incorrect DECIMAL value: '-1'
Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333' Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333'
@ -3431,11 +3431,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 28 -3333.33 -3333.3333 28
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: ''
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
Warning 1292 Truncated incorrect DECIMAL value: '-1' Warning 1292 Truncated incorrect DECIMAL value: '-1'
Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333' Warning 1292 Truncated incorrect DECIMAL value: '-3333.3333'
@ -3455,9 +3455,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 27 -3333.33 -3333.3333 27
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varchar_1000` as decimal(37,2)) AS `CAST(my_varchar_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varchar_1000` AS `my_varchar_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select cast(`t1_values`.`my_varchar_1000` as decimal(37,2)) AS `CAST(my_varchar_1000 AS DECIMAL(37,2))`,`t1_values`.`my_varchar_1000` AS `my_varchar_1000`,`t1_values`.`id` AS `id` from `t1_values` latin1 latin1_swedish_ci
@ -3472,9 +3472,9 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 27 -3333.33 -3333.3333 27
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
DROP VIEW v1; DROP VIEW v1;
@ -3491,11 +3491,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 26 -3333.33 -3333.3333 26
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ' Warning 1292 Truncated incorrect DECIMAL value: ' '
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
SHOW CREATE VIEW v1; SHOW CREATE VIEW v1;
View Create View character_set_client collation_connection View Create View character_set_client collation_connection
@ -3511,11 +3511,11 @@ NULL NULL 1
-1.00 -1 5 -1.00 -1 5
-3333.33 -3333.3333 26 -3333.33 -3333.3333 26
Warnings: Warnings:
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ' Warning 1292 Truncated incorrect DECIMAL value: ' '
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->' Warning 1292 Truncated incorrect DECIMAL value: '<--------30 characters------->'
Error 1366 Incorrect decimal value: '' for column '' at row -1 Error 1366 Incorrect decimal value: '' for column '' at row 0
Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- ' Warning 1292 Truncated incorrect DECIMAL value: ' ---äÖüß@µ*$-- '
DROP VIEW v1; DROP VIEW v1;

View File

@ -723,3 +723,34 @@ SELECT HEX(DAYNAME(19700101));
SET character_set_connection=latin1; SET character_set_connection=latin1;
--echo End of 5.0 tests --echo End of 5.0 tests
--echo Start of 5.1 tests
#
# Checking my_like_range_ucs2
#
SET NAMES utf8;
CREATE TABLE t1 (
a varchar(10) CHARACTER SET ucs2 COLLATE ucs2_czech_ci,
key(a)
);
INSERT INTO t1 VALUES
('aa'),('bb'),('cc'),('dd'),('ee'),('ff'),('gg'),('hh'),('ii'),
('jj'),('kk'),('ll'),('mm'),('nn'),('oo'),('pp'),('rr'),('ss'),
('tt'),('uu'),('vv'),('ww'),('xx'),('yy'),('zz');
INSERT INTO t1 VALUES ('ca'),('cz'),('ch');
INSERT INTO t1 VALUES ('da'),('dz'), (X'0064017E');
# This one should scan only one row
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'b%';
# This one should scan many rows: 'c' is a contraction head
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'c%';
SELECT * FROM t1 WHERE a LIKE 'c%';
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'ch%';
SELECT * FROM t1 WHERE a LIKE 'ch%';
ALTER TABLE t1 MODIFY a VARCHAR(10) CHARACTER SET ucs2 COLLATE ucs2_croatian_ci;
EXPLAIN SELECT * FROM t1 WHERE a LIKE 'd%';
SELECT hex(concat('d',_ucs2 0x017E,'%'));
EXPLAIN SELECT * FROM t1 WHERE a LIKE concat('d',_ucs2 0x017E,'%');
SELECT hex(a) FROM t1 WHERE a LIKE concat('D',_ucs2 0x017E,'%');
DROP TABLE t1;

View File

@ -194,7 +194,6 @@ DROP PROCEDURE sp1;
DROP PROCEDURE sp2; DROP PROCEDURE sp2;
DROP PROCEDURE sp3; DROP PROCEDURE sp3;
# #
# Bug#30059: End-space truncation warnings are inconsistent or incorrect # Bug#30059: End-space truncation warnings are inconsistent or incorrect
# #
@ -235,3 +234,15 @@ DROP TABLE t1;
SHOW ERRORS; SHOW ERRORS;
--echo End of 5.0 tests --echo End of 5.0 tests
#
# Test warning with row numbers
#
set sql_mode = default;
select CAST(a AS DECIMAL(13,5)) FROM (SELECT '' as a) t;
create table t1 (a integer unsigned);
insert into t1 values (1),(-1),(0),(-2);
drop table t1;
--echo End of 5.1 tests

View File

@ -145,7 +145,7 @@ static int simple_parser_deinit(MYSQL_FTPARSER_PARAM *param
the list of search terms when parsing a search string. the list of search terms when parsing a search string.
*/ */
static void add_word(MYSQL_FTPARSER_PARAM *param, char *word, size_t len) static void add_word(MYSQL_FTPARSER_PARAM *param, const unsigned char *word, size_t len)
{ {
MYSQL_FTPARSER_BOOLEAN_INFO bool_info= MYSQL_FTPARSER_BOOLEAN_INFO bool_info=
{ FT_TOKEN_WORD, 0, 0, 0, 0, ' ', 0 }; { FT_TOKEN_WORD, 0, 0, 0, 0, ' ', 0 };
@ -169,7 +169,7 @@ static void add_word(MYSQL_FTPARSER_PARAM *param, char *word, size_t len)
static int simple_parser_parse(MYSQL_FTPARSER_PARAM *param) static int simple_parser_parse(MYSQL_FTPARSER_PARAM *param)
{ {
char *end, *start, *docend= param->doc + param->length; const unsigned char *end, *start, *docend= param->doc + param->length;
number_of_calls++; number_of_calls++;

View File

@ -3208,7 +3208,7 @@ const char * STDCALL mysql_error(MYSQL *mysql)
mysql Connection mysql Connection
EXAMPLE EXAMPLE
4.1.0-alfa -> 40100 MariaDB-4.1.0-alfa -> 40100
NOTES NOTES
We will ensure that a newer server always has a bigger number. We will ensure that a newer server always has a bigger number.
@ -3221,7 +3221,11 @@ ulong STDCALL
mysql_get_server_version(MYSQL *mysql) mysql_get_server_version(MYSQL *mysql)
{ {
uint major, minor, version; uint major, minor, version;
char *pos= mysql->server_version, *end_pos; const char *pos= mysql->server_version;
char *end_pos;
/* Skip possible prefix */
while (*pos && !my_isdigit(&my_charset_latin1, *pos))
pos++;
major= (uint) strtoul(pos, &end_pos, 10); pos=end_pos+1; major= (uint) strtoul(pos, &end_pos, 10); pos=end_pos+1;
minor= (uint) strtoul(pos, &end_pos, 10); pos=end_pos+1; minor= (uint) strtoul(pos, &end_pos, 10); pos=end_pos+1;
version= (uint) strtoul(pos, &end_pos, 10); version= (uint) strtoul(pos, &end_pos, 10);

View File

@ -38,7 +38,7 @@ int decimal_operation_results(int result)
case E_DEC_TRUNCATED: case E_DEC_TRUNCATED:
push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN, push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_WARN,
WARN_DATA_TRUNCATED, ER(WARN_DATA_TRUNCATED), WARN_DATA_TRUNCATED, ER(WARN_DATA_TRUNCATED),
"", (long)-1); "", (ulong) 0);
break; break;
case E_DEC_OVERFLOW: case E_DEC_OVERFLOW:
push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR, push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR,
@ -54,7 +54,7 @@ int decimal_operation_results(int result)
push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR, push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR,
ER_TRUNCATED_WRONG_VALUE_FOR_FIELD, ER_TRUNCATED_WRONG_VALUE_FOR_FIELD,
ER(ER_TRUNCATED_WRONG_VALUE_FOR_FIELD), ER(ER_TRUNCATED_WRONG_VALUE_FOR_FIELD),
"decimal", "", "", (long)-1); "decimal", "", "", (ulong) 0);
break; break;
case E_DEC_OOM: case E_DEC_OOM:
my_error(ER_OUT_OF_RESOURCES, MYF(0)); my_error(ER_OUT_OF_RESOURCES, MYF(0));

View File

@ -4169,8 +4169,10 @@ server.");
Need to unlock as global_system_variables.table_plugin Need to unlock as global_system_variables.table_plugin
was acquired during plugin_init() was acquired during plugin_init()
*/ */
pthread_mutex_lock(&LOCK_global_system_variables);
plugin_unlock(0, global_system_variables.table_plugin); plugin_unlock(0, global_system_variables.table_plugin);
global_system_variables.table_plugin= plugin; global_system_variables.table_plugin= plugin;
pthread_mutex_unlock(&LOCK_global_system_variables);
} }
} }
#if defined(WITH_MARIA_STORAGE_ENGINE) && defined(USE_MARIA_FOR_TMP_TABLES) #if defined(WITH_MARIA_STORAGE_ENGINE) && defined(USE_MARIA_FOR_TMP_TABLES)

View File

@ -3173,22 +3173,22 @@ ER_CANT_CREATE_THREAD
swe "Kan inte skapa en ny tråd (errno %d)" swe "Kan inte skapa en ny tråd (errno %d)"
ukr "îÅ ÍÏÖÕ ÓÔ×ÏÒÉÔÉ ÎÏ×Õ Ç¦ÌËÕ (ÐÏÍÉÌËÁ %d). ñËÝÏ ×É ÎÅ ×ÉËÏÒÉÓÔÁÌÉ ÕÓÀ ÐÁÍ'ÑÔØ, ÔÏ ÐÒÏÞÉÔÁÊÔÅ ÄÏËÕÍÅÎÔÁæÀ ÄÏ ×ÁÛϧ ïó - ÍÏÖÌÉ×Ï ÃÅ ÐÏÍÉÌËÁ ïó" ukr "îÅ ÍÏÖÕ ÓÔ×ÏÒÉÔÉ ÎÏ×Õ Ç¦ÌËÕ (ÐÏÍÉÌËÁ %d). ñËÝÏ ×É ÎÅ ×ÉËÏÒÉÓÔÁÌÉ ÕÓÀ ÐÁÍ'ÑÔØ, ÔÏ ÐÒÏÞÉÔÁÊÔÅ ÄÏËÕÍÅÎÔÁæÀ ÄÏ ×ÁÛϧ ïó - ÍÏÖÌÉ×Ï ÃÅ ÐÏÍÉÌËÁ ïó"
ER_WRONG_VALUE_COUNT_ON_ROW 21S01 ER_WRONG_VALUE_COUNT_ON_ROW 21S01
cze "Po-Bèet sloupcù neodpovídá poètu hodnot na øádku %ld" cze "Po-Bèet sloupcù neodpovídá poètu hodnot na øádku %lu"
dan "Kolonne antallet stemmer ikke overens med antallet af værdier i post %ld" dan "Kolonne antallet stemmer ikke overens med antallet af værdier i post %lu"
nla "Kolom aantal komt niet overeen met waarde aantal in rij %ld" nla "Kolom aantal komt niet overeen met waarde aantal in rij %lu"
eng "Column count doesn't match value count at row %ld" eng "Column count doesn't match value count at row %lu"
est "Tulpade hulk erineb väärtuste hulgast real %ld" est "Tulpade hulk erineb väärtuste hulgast real %lu"
ger "Anzahl der Felder stimmt nicht mit der Anzahl der Werte in Zeile %ld überein" ger "Anzahl der Felder stimmt nicht mit der Anzahl der Werte in Zeile %lu überein"
hun "Az oszlopban talalhato ertek nem egyezik meg a %ld sorban szamitott ertekkel" hun "Az oszlopban talalhato ertek nem egyezik meg a %lu sorban szamitott ertekkel"
ita "Il numero delle colonne non corrisponde al conteggio alla riga %ld" ita "Il numero delle colonne non corrisponde al conteggio alla riga %lu"
kor "Row %ld¿¡¼­ Ä®·³ Ä«¿îÆ®¿Í value Ä«¿îÅÍ¿Í ÀÏÄ¡ÇÏÁö ¾Ê½À´Ï´Ù." kor "Row %lu¿¡¼­ Ä®·³ Ä«¿îÆ®¿Í value Ä«¿îÅÍ¿Í ÀÏÄ¡ÇÏÁö ¾Ê½À´Ï´Ù."
por "Contagem de colunas não confere com a contagem de valores na linha %ld" por "Contagem de colunas não confere com a contagem de valores na linha %lu"
rum "Numarul de coloane nu corespunde cu numarul de valori la linia %ld" rum "Numarul de coloane nu corespunde cu numarul de valori la linia %lu"
rus "ëÏÌÉÞÅÓÔ×Ï ÓÔÏÌÂÃÏ× ÎÅ ÓÏ×ÐÁÄÁÅÔ Ó ËÏÌÉÞÅÓÔ×ÏÍ ÚÎÁÞÅÎÉÊ × ÚÁÐÉÓÉ %ld" rus "ëÏÌÉÞÅÓÔ×Ï ÓÔÏÌÂÃÏ× ÎÅ ÓÏ×ÐÁÄÁÅÔ Ó ËÏÌÉÞÅÓÔ×ÏÍ ÚÎÁÞÅÎÉÊ × ÚÁÐÉÓÉ %lu"
serbian "Broj kolona ne odgovara broju vrednosti u slogu %ld" serbian "Broj kolona ne odgovara broju vrednosti u slogu %lu"
spa "El número de columnas no corresponde al número en la línea %ld" spa "El número de columnas no corresponde al número en la línea %lu"
swe "Antalet kolumner motsvarar inte antalet värden på rad: %ld" swe "Antalet kolumner motsvarar inte antalet värden på rad: %lu"
ukr "ë¦ÌØË¦ÓÔØ ÓÔÏ×ÂÃ¦× ÎÅ ÓЦ×ÐÁÄÁ¤ Ú Ë¦ÌØË¦ÓÔÀ ÚÎÁÞÅÎØ Õ ÓÔÒÏæ %ld" ukr "ë¦ÌØË¦ÓÔØ ÓÔÏ×ÂÃ¦× ÎÅ ÓЦ×ÐÁÄÁ¤ Ú Ë¦ÌØË¦ÓÔÀ ÚÎÁÞÅÎØ Õ ÓÔÒÏæ %lu"
ER_CANT_REOPEN_TABLE ER_CANT_REOPEN_TABLE
cze "Nemohu znovuotev-Bøít tabulku: '%-.192s" cze "Nemohu znovuotev-Bøít tabulku: '%-.192s"
dan "Kan ikke genåbne tabel '%-.192s" dan "Kan ikke genåbne tabel '%-.192s"
@ -4887,29 +4887,29 @@ ER_CUT_VALUE_GROUP_CONCAT
swe "%d rad(er) kapades av group_concat()" swe "%d rad(er) kapades av group_concat()"
ukr "%d line(s) was(were) cut by group_concat()" ukr "%d line(s) was(were) cut by group_concat()"
ER_WARN_TOO_FEW_RECORDS 01000 ER_WARN_TOO_FEW_RECORDS 01000
eng "Row %ld doesn't contain data for all columns" eng "Row %lu doesn't contain data for all columns"
ger "Zeile %ld enthält nicht für alle Felder Daten" ger "Zeile %lu enthält nicht für alle Felder Daten"
nla "Rij %ld bevat niet de data voor alle kolommen" nla "Rij %lu bevat niet de data voor alle kolommen"
por "Conta de registro é menor que a conta de coluna na linha %ld" por "Conta de registro é menor que a conta de coluna na linha %lu"
spa "Línea %ld no contiene datos para todas las columnas" spa "Línea %lu no contiene datos para todas las columnas"
ER_WARN_TOO_MANY_RECORDS 01000 ER_WARN_TOO_MANY_RECORDS 01000
eng "Row %ld was truncated; it contained more data than there were input columns" eng "Row %lu was truncated; it contained more data than there were input columns"
ger "Zeile %ld gekürzt, die Zeile enthielt mehr Daten, als es Eingabefelder gibt" ger "Zeile %lu gekürzt, die Zeile enthielt mehr Daten, als es Eingabefelder gibt"
nla "Regel %ld ingekort, bevatte meer data dan invoer kolommen" nla "Regel %lu ingekort, bevatte meer data dan invoer kolommen"
por "Conta de registro é maior que a conta de coluna na linha %ld" por "Conta de registro é maior que a conta de coluna na linha %lu"
spa "Línea %ld fué truncada; La misma contine mas datos que las que existen en las columnas de entrada" spa "Línea %lu fué truncada; La misma contine mas datos que las que existen en las columnas de entrada"
ER_WARN_NULL_TO_NOTNULL 22004 ER_WARN_NULL_TO_NOTNULL 22004
eng "Column set to default value; NULL supplied to NOT NULL column '%s' at row %ld" eng "Column set to default value; NULL supplied to NOT NULL column '%s' at row %lu"
ger "Feld auf Vorgabewert gesetzt, da NULL für NOT-NULL-Feld '%s' in Zeile %ld angegeben" ger "Feld auf Vorgabewert gesetzt, da NULL für NOT-NULL-Feld '%s' in Zeile %lu angegeben"
por "Dado truncado, NULL fornecido para NOT NULL coluna '%s' na linha %ld" por "Dado truncado, NULL fornecido para NOT NULL coluna '%s' na linha %lu"
spa "Datos truncado, NULL suministrado para NOT NULL columna '%s' en la línea %ld" spa "Datos truncado, NULL suministrado para NOT NULL columna '%s' en la línea %lu"
ER_WARN_DATA_OUT_OF_RANGE 22003 ER_WARN_DATA_OUT_OF_RANGE 22003
eng "Out of range value for column '%s' at row %ld" eng "Out of range value for column '%s' at row %lu"
WARN_DATA_TRUNCATED 01000 WARN_DATA_TRUNCATED 01000
eng "Data truncated for column '%s' at row %ld" eng "Data truncated for column '%s' at row %lu"
ger "Daten abgeschnitten für Feld '%s' in Zeile %ld" ger "Daten abgeschnitten für Feld '%s' in Zeile %lu"
por "Dado truncado para coluna '%s' na linha %ld" por "Dado truncado para coluna '%s' na linha %lu"
spa "Datos truncados para columna '%s' en la línea %ld" spa "Datos truncados para columna '%s' en la línea %lu"
ER_WARN_USING_OTHER_HANDLER ER_WARN_USING_OTHER_HANDLER
eng "Using storage engine %s for table '%s'" eng "Using storage engine %s for table '%s'"
ger "Für Tabelle '%s' wird Speicher-Engine %s benutzt" ger "Für Tabelle '%s' wird Speicher-Engine %s benutzt"
@ -5090,8 +5090,8 @@ ER_UNKNOWN_TIME_ZONE
eng "Unknown or incorrect time zone: '%-.64s'" eng "Unknown or incorrect time zone: '%-.64s'"
ger "Unbekannte oder falsche Zeitzone: '%-.64s'" ger "Unbekannte oder falsche Zeitzone: '%-.64s'"
ER_WARN_INVALID_TIMESTAMP ER_WARN_INVALID_TIMESTAMP
eng "Invalid TIMESTAMP value in column '%s' at row %ld" eng "Invalid TIMESTAMP value in column '%s' at row %lu"
ger "Ungültiger TIMESTAMP-Wert in Feld '%s', Zeile %ld" ger "Ungültiger TIMESTAMP-Wert in Feld '%s', Zeile %lu"
ER_INVALID_CHARACTER_STRING ER_INVALID_CHARACTER_STRING
eng "Invalid %s character string: '%.64s'" eng "Invalid %s character string: '%.64s'"
ger "Ungültiger %s-Zeichen-String: '%.64s'" ger "Ungültiger %s-Zeichen-String: '%.64s'"
@ -5322,8 +5322,8 @@ ER_DIVISION_BY_ZERO 22012
eng "Division by 0" eng "Division by 0"
ger "Division durch 0" ger "Division durch 0"
ER_TRUNCATED_WRONG_VALUE_FOR_FIELD ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
eng "Incorrect %-.32s value: '%-.128s' for column '%.192s' at row %ld" eng "Incorrect %-.32s value: '%-.128s' for column '%.192s' at row %lu"
ger "Falscher %-.32s-Wert: '%-.128s' für Feld '%.192s' in Zeile %ld" ger "Falscher %-.32s-Wert: '%-.128s' für Feld '%.192s' in Zeile %lu"
ER_ILLEGAL_VALUE_FOR_TYPE 22007 ER_ILLEGAL_VALUE_FOR_TYPE 22007
eng "Illegal %s '%-.192s' value found during parsing" eng "Illegal %s '%-.192s' value found during parsing"
ger "Nicht zulässiger %s-Wert '%-.192s' beim Parsen gefunden" ger "Nicht zulässiger %s-Wert '%-.192s' beim Parsen gefunden"
@ -5456,8 +5456,8 @@ ER_PROC_AUTO_REVOKE_FAIL
eng "Failed to revoke all privileges to dropped routine" eng "Failed to revoke all privileges to dropped routine"
ger "Rücknahme aller Rechte für die gelöschte Routine fehlgeschlagen" ger "Rücknahme aller Rechte für die gelöschte Routine fehlgeschlagen"
ER_DATA_TOO_LONG 22001 ER_DATA_TOO_LONG 22001
eng "Data too long for column '%s' at row %ld" eng "Data too long for column '%s' at row %lu"
ger "Daten zu lang für Feld '%s' in Zeile %ld" ger "Daten zu lang für Feld '%s' in Zeile %lu"
ER_SP_BAD_SQLSTATE 42000 ER_SP_BAD_SQLSTATE 42000
eng "Bad SQLSTATE: '%s'" eng "Bad SQLSTATE: '%s'"
ger "Ungültiger SQLSTATE: '%s'" ger "Ungültiger SQLSTATE: '%s'"

View File

@ -1117,18 +1117,27 @@ be equal for the Statement-format replication to work";
goto err; goto err;
} }
} }
else if (is_network_error(mysql_errno(mysql))) else if (is_network_error(err_code= mysql_errno(mysql)))
{ {
mi->report(WARNING_LEVEL, mysql_errno(mysql), mi->report(ERROR_LEVEL, err_code,
"Get master TIME_ZONE failed with error: %s", mysql_error(mysql)); "Get master TIME_ZONE failed with error: %s",
mysql_error(mysql));
goto network_err; goto network_err;
} }
else if (err_code == ER_UNKNOWN_SYSTEM_VARIABLE)
{
/* We use ERROR_LEVEL to get the error logged to file */
mi->report(ERROR_LEVEL, err_code,
"MySQL master doesn't have a TIME_ZONE variable. Note that"
"if your timezone is not same between master and slave, your "
"slave may get wrong data into timestamp columns");
}
else else
{ {
/* Fatal error */ /* Fatal error */
errmsg= "The slave I/O thread stops because a fatal error is encountered \ errmsg= "The slave I/O thread stops because a fatal error is encountered \
when it try to get the value of TIME_ZONE global variable from master."; when it try to get the value of TIME_ZONE global variable from master.";
err_code= mysql_errno(mysql);
sprintf(err_buff, "%s Error: %s", errmsg, mysql_error(mysql)); sprintf(err_buff, "%s Error: %s", errmsg, mysql_error(mysql));
goto err; goto err;
} }

View File

@ -8488,19 +8488,26 @@ bool remove_table_from_cache(THD *thd, const char *db, const char *table_name,
result=1; result=1;
} }
/* Kill delayed insert threads */ /* Kill delayed insert threads */
if ((in_use->system_thread & SYSTEM_THREAD_DELAYED_INSERT) && if ((in_use->system_thread & SYSTEM_THREAD_DELAYED_INSERT))
! in_use->killed)
{ {
in_use->killed= THD::KILL_CONNECTION; if (!in_use->killed)
pthread_mutex_lock(&in_use->mysys_var->mutex); {
if (in_use->mysys_var->current_cond) in_use->killed= THD::KILL_CONNECTION;
{ pthread_mutex_lock(&in_use->mysys_var->mutex);
pthread_mutex_lock(in_use->mysys_var->current_mutex); if (in_use->mysys_var->current_cond)
signalled= 1; {
pthread_cond_broadcast(in_use->mysys_var->current_cond); pthread_mutex_lock(in_use->mysys_var->current_mutex);
pthread_mutex_unlock(in_use->mysys_var->current_mutex); signalled= 1;
} pthread_cond_broadcast(in_use->mysys_var->current_cond);
pthread_mutex_unlock(&in_use->mysys_var->mutex); pthread_mutex_unlock(in_use->mysys_var->current_mutex);
}
pthread_mutex_unlock(&in_use->mysys_var->mutex);
}
/*
Don't abort locks. Instead give the delayed insert thread
time to finish it's inserts and die gracefully.
*/
continue;
} }
/* /*
Now we must abort all tables locks used by this thread Now we must abort all tables locks used by this thread

View File

@ -2046,7 +2046,7 @@ bool select_export::send_data(List<Item> &items)
ER_TRUNCATED_WRONG_VALUE_FOR_FIELD, ER_TRUNCATED_WRONG_VALUE_FOR_FIELD,
ER(ER_TRUNCATED_WRONG_VALUE_FOR_FIELD), ER(ER_TRUNCATED_WRONG_VALUE_FOR_FIELD),
"string", printable_buff, "string", printable_buff,
item->name, row_count); item->name, (ulong) row_count);
} }
cvt_str.length(bytes); cvt_str.length(bytes);
res= &cvt_str; res= &cvt_str;

View File

@ -2618,7 +2618,7 @@ bool Delayed_insert::handle_inserts(void)
or if another thread is removing the current table definition or if another thread is removing the current table definition
from the table cache. from the table cache.
*/ */
my_error(ER_DELAYED_CANT_CHANGE_LOCK,MYF(ME_FATALERROR), my_error(ER_DELAYED_CANT_CHANGE_LOCK, MYF(ME_FATALERROR | ME_NOREFRESH),
table->s->table_name.str); table->s->table_name.str);
goto err; goto err;
} }
@ -2791,10 +2791,11 @@ bool Delayed_insert::handle_inserts(void)
query_cache_invalidate3(&thd, table, 1); query_cache_invalidate3(&thd, table, 1);
if (thr_reschedule_write_lock(*thd.lock->locks)) if (thr_reschedule_write_lock(*thd.lock->locks))
{ {
/* This is not known to happen. */ /* This is not known to happen. */
my_error(ER_DELAYED_CANT_CHANGE_LOCK,MYF(ME_FATALERROR), my_error(ER_DELAYED_CANT_CHANGE_LOCK,
table->s->table_name.str); MYF(ME_FATALERROR | ME_NOREFRESH),
goto err; table->s->table_name.str);
goto err;
} }
if (!using_bin_log) if (!using_bin_log)
table->file->extra(HA_EXTRA_WRITE_CACHE); table->file->extra(HA_EXTRA_WRITE_CACHE);

View File

@ -1,5 +1,5 @@
/* /*
Copyright (c) 2008, Patrick Galbraith Copyright (c) 2008-2009, Patrick Galbraith & Antony Curtis
All rights reserved. All rights reserved.
Redistribution and use in source and binary forms, with or without Redistribution and use in source and binary forms, with or without
@ -308,7 +308,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/ */
#define MYSQL_SERVER 1q #define MYSQL_SERVER 1
#include "mysql_priv.h" #include "mysql_priv.h"
#include <mysql/plugin.h> #include <mysql/plugin.h>
@ -1627,7 +1627,13 @@ static int free_server(federatedx_txn *txn, FEDERATEDX_SERVER *server)
{ {
MEM_ROOT mem_root; MEM_ROOT mem_root;
txn->close(server); if (!txn)
{
federatedx_txn tmp_txn;
tmp_txn.close(server);
}
else
txn->close(server);
DBUG_ASSERT(server->io_count == 0); DBUG_ASSERT(server->io_count == 0);
@ -1785,21 +1791,25 @@ int ha_federatedx::close(void)
if (stored_result) if (stored_result)
retval= free_result(); retval= free_result();
/* Disconnect from mysql. thd may be null during refresh */ /* Disconnect from mysql */
txn= thd ? get_txn(thd, true) : new federatedx_txn(); if (!thd || !(txn= get_txn(thd, true)))
{
federatedx_txn tmp_txn;
if (txn) tmp_txn.release(&io);
DBUG_ASSERT(io == NULL);
if ((error= free_share(&tmp_txn, share)))
retval= error;
}
else
{ {
txn->release(&io); txn->release(&io);
DBUG_ASSERT(io == NULL); DBUG_ASSERT(io == NULL);
if ((error= free_share(txn, share))) if ((error= free_share(txn, share)))
retval= error; retval= error;
if (!thd)
delete txn;
} }
DBUG_RETURN(retval); DBUG_RETURN(retval);
} }
@ -2793,14 +2803,16 @@ int ha_federatedx::rnd_end()
int ha_federatedx::free_result() int ha_federatedx::free_result()
{ {
int error; int error;
federatedx_io *tmp_io= 0, **iop;
DBUG_ASSERT(stored_result); DBUG_ASSERT(stored_result);
if ((error= txn->acquire(share, FALSE, &io))) if (!*(iop= &io) && (error= txn->acquire(share, TRUE, (iop= &tmp_io))))
{ {
DBUG_ASSERT(0); // Fail when testing DBUG_ASSERT(0); // Fail when testing
return error; return error;
} }
io->free_result(stored_result); (*iop)->free_result(stored_result);
stored_result= 0; stored_result= 0;
txn->release(&tmp_io);
return 0; return 0;
} }
@ -2985,7 +2997,7 @@ int ha_federatedx::info(uint flag)
{ {
char error_buffer[FEDERATEDX_QUERY_BUFFER_SIZE]; char error_buffer[FEDERATEDX_QUERY_BUFFER_SIZE];
uint error_code; uint error_code;
federatedx_io *tmp_io= 0; federatedx_io *tmp_io= 0, **iop= 0;
DBUG_ENTER("ha_federatedx::info"); DBUG_ENTER("ha_federatedx::info");
error_code= ER_QUERY_ON_FOREIGN_DATA_SOURCE; error_code= ER_QUERY_ON_FOREIGN_DATA_SOURCE;
@ -2993,7 +3005,7 @@ int ha_federatedx::info(uint flag)
/* we want not to show table status if not needed to do so */ /* we want not to show table status if not needed to do so */
if (flag & (HA_STATUS_VARIABLE | HA_STATUS_CONST | HA_STATUS_AUTO)) if (flag & (HA_STATUS_VARIABLE | HA_STATUS_CONST | HA_STATUS_AUTO))
{ {
if ((error_code= txn->acquire(share, TRUE, &tmp_io))) if (!*(iop= &io) && (error_code= txn->acquire(share, TRUE, (iop= &tmp_io))))
goto fail; goto fail;
} }
@ -3006,13 +3018,13 @@ int ha_federatedx::info(uint flag)
if (flag & HA_STATUS_CONST) if (flag & HA_STATUS_CONST)
stats.block_size= 4096; stats.block_size= 4096;
if (tmp_io->table_metadata(&stats, share->table_name, if ((*iop)->table_metadata(&stats, share->table_name,
share->table_name_length, flag)) share->table_name_length, flag))
goto error; goto error;
} }
if (flag & HA_STATUS_AUTO) if (flag & HA_STATUS_AUTO)
stats.auto_increment_value= tmp_io->last_insert_id(); stats.auto_increment_value= (*iop)->last_insert_id();
/* /*
If ::info created it's own transaction, close it. This happens in case If ::info created it's own transaction, close it. This happens in case
@ -3023,10 +3035,10 @@ int ha_federatedx::info(uint flag)
DBUG_RETURN(0); DBUG_RETURN(0);
error: error:
if (tmp_io) if (iop && *iop)
{ {
my_sprintf(error_buffer, (error_buffer, ": %d : %s", my_sprintf(error_buffer, (error_buffer, ": %d : %s",
tmp_io->error_code(), tmp_io->error_str())); (*iop)->error_code(), (*iop)->error_str()));
my_error(error_code, MYF(0), error_buffer); my_error(error_code, MYF(0), error_buffer);
} }
else else

View File

@ -1498,6 +1498,14 @@ void my_hash_sort_ucs2_bin(CHARSET_INFO *cs __attribute__((unused)),
} }
} }
static inline my_wc_t
ucs2_to_wc(const uchar *ptr)
{
return (((uint) ptr[0]) << 8) + ptr[1];
}
/* /*
** Calculate min_str and max_str that ranges a LIKE string. ** Calculate min_str and max_str that ranges a LIKE string.
** Arguments: ** Arguments:
@ -1531,6 +1539,7 @@ my_bool my_like_range_ucs2(CHARSET_INFO *cs,
for ( ; ptr + 1 < end && min_str + 1 < min_end && charlen > 0 for ( ; ptr + 1 < end && min_str + 1 < min_end && charlen > 0
; ptr+=2, charlen--) ; ptr+=2, charlen--)
{ {
my_wc_t wc;
if (ptr[0] == '\0' && ptr[1] == escape && ptr + 1 < end) if (ptr[0] == '\0' && ptr[1] == escape && ptr + 1 < end)
{ {
ptr+=2; /* Skip escape */ ptr+=2; /* Skip escape */
@ -1567,9 +1576,9 @@ fill_max_and_min:
} }
if (have_contractions && ptr + 3 < end && if (have_contractions && ptr + 3 < end &&
ptr[0] == '\0' && my_uca_can_be_contraction_head(cs, (wc= ucs2_to_wc((uchar*) ptr))))
my_uca_can_be_contraction_head(cs, (uchar) ptr[1]))
{ {
my_wc_t wc2;
/* Contraction head found */ /* Contraction head found */
if (ptr[2] == '\0' && (ptr[3] == w_one || ptr[3] == w_many)) if (ptr[2] == '\0' && (ptr[3] == w_one || ptr[3] == w_many))
{ {
@ -1581,9 +1590,8 @@ fill_max_and_min:
Check if the second letter can be contraction part, Check if the second letter can be contraction part,
and if two letters really produce a contraction. and if two letters really produce a contraction.
*/ */
if (ptr[2] == '\0' && if (my_uca_can_be_contraction_tail(cs, (wc2= ucs2_to_wc((uchar*) ptr + 2))) &&
my_uca_can_be_contraction_tail(cs, (uchar) ptr[3]) && my_uca_contraction2_weight(cs, wc , wc2))
my_uca_contraction2_weight(cs,(uchar) ptr[1], (uchar) ptr[3]))
{ {
/* Contraction found */ /* Contraction found */
if (charlen == 1 || min_str + 2 >= min_end) if (charlen == 1 || min_str + 2 >= min_end)

View File

@ -24,7 +24,7 @@ LDADD = $(top_builddir)/unittest/mytap/libmytap.a \
$(top_builddir)/strings/libmystrings.a $(top_builddir)/strings/libmystrings.a
EXTRA_DIST = CMakeLists.txt EXTRA_DIST = CMakeLists.txt
noinst_PROGRAMS = bitmap-t base64-t lf-t waiting_threads-t noinst_PROGRAMS = bitmap-t base64-t my_atomic-t lf-t waiting_threads-t
if NEED_THREAD if NEED_THREAD
# my_atomic-t is used to check thread functions, so it is safe to # my_atomic-t is used to check thread functions, so it is safe to

View File

@ -19,7 +19,6 @@
static my_bool ssl_algorithms_added = FALSE; static my_bool ssl_algorithms_added = FALSE;
static my_bool ssl_error_strings_loaded= FALSE; static my_bool ssl_error_strings_loaded= FALSE;
static int verify_depth = 0;
static unsigned char dh512_p[]= static unsigned char dh512_p[]=
{ {