mirror of
https://github.com/MariaDB/server.git
synced 2025-01-17 20:42:30 +01:00
Automerge
This commit is contained in:
commit
156832f039
438 changed files with 5574 additions and 2609 deletions
|
@ -1928,3 +1928,5 @@ libmysqld/ha_federatedx.cc
|
|||
tmp
|
||||
libmysqld/debug_sync.cc
|
||||
storage/pbxt/bin/xtstat
|
||||
mysql-test/mtr_command
|
||||
scripts/convert-debug-for-diff
|
||||
|
|
|
@ -83,6 +83,3 @@ EXTRA_DIST = FINISH.sh \
|
|||
compile-solaris-x86-32-debug-forte \
|
||||
compile-solaris-x86-forte-32 \
|
||||
util.sh
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -91,29 +91,26 @@ path=`dirname $0`
|
|||
get_make_parallel_flag
|
||||
|
||||
# SSL library to use.--with-ssl will select our bundled yaSSL
|
||||
# implementation of SSL. To use openSSl you will nee too point out
|
||||
# the location of openSSL headers and lbs on your system.
|
||||
# implementation of SSL. To use OpenSSL you will need to specify
|
||||
# the location of OpenSSL headers and libs on your system.
|
||||
# Ex --with-ssl=/usr
|
||||
SSL_LIBRARY=--with-ssl
|
||||
|
||||
if [ "x$warning_mode" != "xpedantic" ]; then
|
||||
# Both C and C++ warnings
|
||||
warnings="-Wimplicit -Wreturn-type -Wswitch -Wtrigraphs -Wcomment -W"
|
||||
warnings="$warnings -Wchar-subscripts -Wformat -Wparentheses -Wsign-compare"
|
||||
warnings="$warnings -Wwrite-strings -Wunused-function -Wunused-label -Wunused-value -Wunused-variable"
|
||||
warnings="-Wall -Wextra -Wunused -Wwrite-strings"
|
||||
|
||||
# For more warnings, uncomment the following line
|
||||
# warnings="$global_warnings -Wshadow"
|
||||
# warnings="$warnings -Wshadow"
|
||||
|
||||
# C warnings
|
||||
c_warnings="$warnings -Wunused-parameter"
|
||||
c_warnings="$warnings"
|
||||
# C++ warnings
|
||||
cxx_warnings="$warnings"
|
||||
cxx_warnings="$warnings -Wno-unused-parameter"
|
||||
# cxx_warnings="$cxx_warnings -Woverloaded-virtual -Wsign-promo"
|
||||
cxx_warnings="$cxx_warnings -Wreorder"
|
||||
cxx_warnings="$cxx_warnings -Wctor-dtor-privacy -Wnon-virtual-dtor"
|
||||
# Added unless --with-debug=full
|
||||
debug_extra_cflags="-O0 -g3 -gdwarf-2" #1 -Wuninitialized"
|
||||
debug_extra_cflags="-O0 -g3 -gdwarf-2"
|
||||
else
|
||||
warnings="-W -Wall -ansi -pedantic -Wno-long-long -Wno-unused -D_POSIX_SOURCE"
|
||||
c_warnings="$warnings"
|
||||
|
@ -182,8 +179,7 @@ max_no_embedded_configs="$SSL_LIBRARY --with-plugins=max"
|
|||
max_no_qc_configs="$SSL_LIBRARY --with-plugins=max --without-query-cache"
|
||||
max_no_ndb_configs="$SSL_LIBRARY --with-plugins=max-no-ndb --with-embedded-server --with-libevent"
|
||||
max_configs="$SSL_LIBRARY --with-plugins=max --with-embedded-server --with-libevent"
|
||||
# Disable NDB in maria max builds
|
||||
max_configs=$max_no_ndb_configs
|
||||
all_configs="$SSL_LIBRARY --with-plugins=max --with-plugin-ndbcluster --with-embedded-server --with-libevent"
|
||||
|
||||
#
|
||||
# CPU and platform specific compilation flags.
|
||||
|
|
|
@ -181,14 +181,17 @@ check_cpu () {
|
|||
cc=$CC
|
||||
fi
|
||||
|
||||
cc_ver=`$cc --version | sed 1q`
|
||||
cc_verno=`echo $cc_ver | sed -e 's/^.*(GCC)//g; s/[^0-9. ]//g; s/^ *//g; s/ .*//g'`
|
||||
set -- `echo $cc_verno | tr '.' ' '`
|
||||
cc_major=$1
|
||||
cc_minor=$2
|
||||
cc_patch=$3
|
||||
cc_comp=`expr $cc_major '*' 100 '+' $cc_minor`
|
||||
|
||||
# check if compiler is gcc and dump its version
|
||||
cc_verno=`$cc -dumpversion 2>/dev/null`
|
||||
if test "x$?" = "x0" ; then
|
||||
set -- `echo $cc_verno | tr '.' ' '`
|
||||
cc_ver="GCC"
|
||||
cc_major=$1
|
||||
cc_minor=$2
|
||||
cc_patch=$3
|
||||
cc_comp=`expr $cc_major '*' 100 '+' $cc_minor`
|
||||
fi
|
||||
|
||||
case "$cc_ver--$cc_verno" in
|
||||
*GCC*)
|
||||
# different gcc backends (and versions) have different CPU flags
|
||||
|
@ -229,7 +232,7 @@ check_cpu () {
|
|||
fi
|
||||
while [ "$cpu_arg" ] ; do
|
||||
printf "testing $cpu_arg ... " >&2
|
||||
|
||||
|
||||
# compile check
|
||||
eval "$cc -c $check_cpu_cflags __test.c" 2>/dev/null
|
||||
if test "x$?" = "x0" ; then
|
||||
|
@ -243,5 +246,5 @@ check_cpu () {
|
|||
done
|
||||
rm __test.*
|
||||
}
|
||||
|
||||
|
||||
check_cpu
|
||||
|
|
7
BUILD/compile-amd64-debug-all
Executable file
7
BUILD/compile-amd64-debug-all
Executable file
|
@ -0,0 +1,7 @@
|
|||
#! /bin/sh
|
||||
path=`dirname $0`
|
||||
. "$path/SETUP.sh"
|
||||
extra_flags="$amd64_cflags $debug_cflags"
|
||||
extra_configs="$amd64_configs $debug_configs $all_configs"
|
||||
|
||||
. "$path/FINISH.sh"
|
10
BUILD/compile-pentium-debug-all
Executable file
10
BUILD/compile-pentium-debug-all
Executable file
|
@ -0,0 +1,10 @@
|
|||
#! /bin/sh
|
||||
|
||||
path=`dirname $0`
|
||||
set -- "$@" --with-debug=full
|
||||
. "$path/SETUP.sh"
|
||||
|
||||
extra_flags="$pentium_cflags $debug_cflags"
|
||||
extra_configs="$pentium_configs $debug_configs $all_configs $error_inject --with-experimental-collations"
|
||||
|
||||
. "$path/FINISH.sh"
|
12
BUILD/compile-pentium64-debug-all
Executable file
12
BUILD/compile-pentium64-debug-all
Executable file
|
@ -0,0 +1,12 @@
|
|||
#! /bin/sh
|
||||
|
||||
path=`dirname $0`
|
||||
set -- "$@" --with-debug=full
|
||||
. "$path/SETUP.sh"
|
||||
|
||||
extra_flags="$pentium64_cflags $debug_cflags"
|
||||
extra_configs="$pentium_configs $debug_configs $all_configs"
|
||||
|
||||
extra_configs="$extra_configs "
|
||||
CC="$CC --pipe"
|
||||
. "$path/FINISH.sh"
|
|
@ -37,6 +37,3 @@ uninstall-local:
|
|||
@RM@ -f $(DESTDIR)$(infodir)/mysql.info ; \
|
||||
@RM@ -f $(DESTDIR)$(pkgdatadir)/ChangeLog ; \
|
||||
fi
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -324,7 +324,7 @@ abi_check_all: $(TEST_PREPROCESSOR_HEADER)
|
|||
do_abi_check:
|
||||
set -ex; \
|
||||
for file in $(abi_headers); do \
|
||||
@CC@ -E -nostdinc -dI \
|
||||
@CC@ -E -nostdinc -dI -DMYSQL_ABI_CHECK \
|
||||
-I$(top_srcdir)/include \
|
||||
-I$(top_srcdir)/include/mysql \
|
||||
-I$(top_srcdir)/sql \
|
||||
|
@ -340,6 +340,3 @@ do_abi_check:
|
|||
@DIFF@ -w $$file.pp $(top_builddir)/abi_check.out; \
|
||||
@RM@ $(top_builddir)/abi_check.out; \
|
||||
done
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -122,6 +122,3 @@ link_sources:
|
|||
rm -f $(srcdir)/my_user.c; \
|
||||
@LN_CP_F@ $(top_srcdir)/sql-common/my_user.c my_user.c;
|
||||
echo timestamp > link_sources;
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -156,6 +156,7 @@ static my_bool ignore_errors=0,wait_flag=0,quick=0,
|
|||
static my_bool debug_info_flag, debug_check_flag, batch_abort_on_error;
|
||||
static my_bool column_types_flag;
|
||||
static my_bool preserve_comments= 0;
|
||||
static my_bool in_com_source, aborted= 0;
|
||||
static ulong opt_max_allowed_packet, opt_net_buffer_length;
|
||||
static uint verbose=0,opt_silent=0,opt_mysql_port=0, opt_local_infile=0;
|
||||
static uint my_end_arg;
|
||||
|
@ -1087,6 +1088,7 @@ int main(int argc,char *argv[])
|
|||
"\\N [\\d]> ",MYF(MY_WME));
|
||||
current_prompt = my_strdup(default_prompt,MYF(MY_WME));
|
||||
prompt_counter=0;
|
||||
aborted= 0;
|
||||
|
||||
outfile[0]=0; // no (default) outfile
|
||||
strmov(pager, "stdout"); // the default, if --pager wasn't given
|
||||
|
@ -1281,8 +1283,10 @@ sig_handler mysql_end(int sig)
|
|||
/*
|
||||
This function handles sigint calls
|
||||
If query is in process, kill query
|
||||
If 'source' is executed, abort source command
|
||||
no query in process, terminate like previous behavior
|
||||
*/
|
||||
|
||||
sig_handler handle_sigint(int sig)
|
||||
{
|
||||
char kill_buffer[40];
|
||||
|
@ -1321,7 +1325,8 @@ sig_handler handle_sigint(int sig)
|
|||
mysql_close(kill_mysql);
|
||||
tee_fprintf(stdout, "Ctrl-C -- query killed. Continuing normally.\n");
|
||||
interrupted_query= 0;
|
||||
|
||||
if (in_com_source)
|
||||
aborted= 1; // Abort source command
|
||||
return;
|
||||
|
||||
err:
|
||||
|
@ -1878,7 +1883,7 @@ static int read_and_execute(bool interactive)
|
|||
String buffer;
|
||||
#endif
|
||||
|
||||
char *line;
|
||||
char *line= 0;
|
||||
char in_string=0;
|
||||
ulong line_number=0;
|
||||
bool ml_comment= 0;
|
||||
|
@ -1886,7 +1891,7 @@ static int read_and_execute(bool interactive)
|
|||
bool truncated= 0;
|
||||
status.exit_status=1;
|
||||
|
||||
for (;;)
|
||||
while (!aborted)
|
||||
{
|
||||
if (!interactive)
|
||||
{
|
||||
|
@ -3650,7 +3655,7 @@ xmlencode_print(const char *src, uint length)
|
|||
tee_fputs("NULL", PAGER);
|
||||
else
|
||||
{
|
||||
for (const char *p = src; length; *p++, length--)
|
||||
for (const char *p = src; length; p++, length--)
|
||||
{
|
||||
const char *t;
|
||||
if ((t = array_value(xmlmeta, *p)))
|
||||
|
@ -4066,17 +4071,19 @@ static int com_source(String *buffer, char *line)
|
|||
status.file_name=source_name;
|
||||
glob_buffer.length(0); // Empty command buffer
|
||||
ignore_errors= !batch_abort_on_error;
|
||||
in_com_source= 1;
|
||||
error= read_and_execute(false);
|
||||
ignore_errors= save_ignore_errors;
|
||||
status=old_status; // Continue as before
|
||||
in_com_source= aborted= 0;
|
||||
my_fclose(sql_file,MYF(0));
|
||||
batch_readline_end(line_buff);
|
||||
/*
|
||||
If we got an error during source operation, don't abort the client
|
||||
if ignore_errors is set
|
||||
*/
|
||||
if (error && batch_abort_on_error && ignore_errors)
|
||||
error= -1;
|
||||
if (error && !batch_abort_on_error && ignore_errors)
|
||||
error= -1; // Ignore error
|
||||
return error;
|
||||
}
|
||||
|
||||
|
@ -4760,7 +4767,7 @@ static const char *construct_prompt()
|
|||
struct tm *t = localtime(&lclock);
|
||||
|
||||
/* parse thru the settings for the prompt */
|
||||
for (char *c = current_prompt; *c ; *c++)
|
||||
for (char *c = current_prompt; *c ; c++)
|
||||
{
|
||||
if (*c != PROMPT_CHAR)
|
||||
processed_prompt.append(*c);
|
||||
|
|
|
@ -71,8 +71,8 @@ static struct my_option my_long_options[] =
|
|||
&opt_auto_repair, &opt_auto_repair, 0, GET_BOOL, NO_ARG, 0,
|
||||
0, 0, 0, 0, 0},
|
||||
{"character-sets-dir", OPT_CHARSETS_DIR,
|
||||
"Directory for character set files.", &charsets_dir,
|
||||
&charsets_dir, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
"Directory for character set files.", (char**) &charsets_dir,
|
||||
(char**) &charsets_dir, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"check", 'c', "Check table for errors.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0,
|
||||
0, 0, 0, 0},
|
||||
{"check-only-changed", 'C',
|
||||
|
|
|
@ -211,8 +211,8 @@ static struct my_option my_long_options[] =
|
|||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#endif
|
||||
{"character-sets-dir", OPT_CHARSETS_DIR,
|
||||
"Directory for character set files.", &charsets_dir,
|
||||
&charsets_dir, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
"Directory for character set files.", (char**) &charsets_dir,
|
||||
(char**) &charsets_dir, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"comments", 'i', "Write additional information.",
|
||||
&opt_comments, &opt_comments, 0, GET_BOOL, NO_ARG,
|
||||
1, 0, 0, 0, 0, 0},
|
||||
|
@ -242,8 +242,8 @@ static struct my_option my_long_options[] =
|
|||
{"debug", '#', "This is a non-debug version. Catch this and exit.",
|
||||
0,0, 0, GET_DISABLED, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#else
|
||||
{"debug", '#', "Output debug log.", &default_dbug_option,
|
||||
&default_dbug_option, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"debug", '#', "Output debug log.", (char**) &default_dbug_option,
|
||||
(char**) &default_dbug_option, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#endif
|
||||
{"debug-check", OPT_DEBUG_CHECK, "Check memory and open file usage at exit.",
|
||||
&debug_check_flag, &debug_check_flag, 0,
|
||||
|
|
|
@ -73,8 +73,8 @@ static struct my_option my_long_options[] =
|
|||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#endif
|
||||
{"character-sets-dir", OPT_CHARSETS_DIR,
|
||||
"Directory for character set files.", &charsets_dir,
|
||||
&charsets_dir, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
"Directory for character set files.", (char**) &charsets_dir,
|
||||
(char**) &charsets_dir, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"default-character-set", OPT_DEFAULT_CHARSET,
|
||||
"Set the default character set.", &default_charset,
|
||||
&default_charset, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
|
|
|
@ -164,7 +164,7 @@ static struct my_option my_long_options[] =
|
|||
0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#endif
|
||||
{"character-sets-dir", 'c', "Directory for character set files.",
|
||||
&charsets_dir, &charsets_dir, 0, GET_STR, REQUIRED_ARG, 0,
|
||||
(char**) &charsets_dir, (char**) &charsets_dir, 0, GET_STR, REQUIRED_ARG, 0,
|
||||
0, 0, 0, 0, 0},
|
||||
{"default-character-set", OPT_DEFAULT_CHARSET,
|
||||
"Set the default character set.", &default_charset,
|
||||
|
@ -669,8 +669,7 @@ list_fields(MYSQL *mysql,const char *db,const char *table,
|
|||
char query[1024],*end;
|
||||
MYSQL_RES *result;
|
||||
MYSQL_ROW row;
|
||||
ulong rows;
|
||||
LINT_INIT(rows);
|
||||
ulong UNINIT_VAR(rows);
|
||||
|
||||
if (mysql_select_db(mysql,db))
|
||||
{
|
||||
|
|
|
@ -543,7 +543,7 @@ static struct my_option my_long_options[] =
|
|||
0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"auto-generate-sql-load-type", OPT_SLAP_AUTO_GENERATE_SQL_LOAD_TYPE,
|
||||
"Specify test load type: mixed, update, write, key, or read; default is mixed.",
|
||||
&auto_generate_sql_type, &auto_generate_sql_type,
|
||||
(char**) &auto_generate_sql_type, (char**) &auto_generate_sql_type,
|
||||
0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"auto-generate-sql-secondary-indexes",
|
||||
OPT_SLAP_AUTO_GENERATE_SECONDARY_INDEXES,
|
||||
|
@ -574,13 +574,13 @@ static struct my_option my_long_options[] =
|
|||
&opt_compress, &opt_compress, 0, GET_BOOL, NO_ARG, 0, 0, 0,
|
||||
0, 0, 0},
|
||||
{"concurrency", 'c', "Number of clients to simulate for query to run.",
|
||||
&concurrency_str, &concurrency_str, 0, GET_STR,
|
||||
(char**) &concurrency_str, (char**) &concurrency_str, 0, GET_STR,
|
||||
REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"create", OPT_SLAP_CREATE_STRING, "File or string to use create tables.",
|
||||
&create_string, &create_string, 0, GET_STR, REQUIRED_ARG,
|
||||
0, 0, 0, 0, 0, 0},
|
||||
{"create-schema", OPT_CREATE_SLAP_SCHEMA, "Schema to run tests in.",
|
||||
&create_schema_string, &create_schema_string, 0, GET_STR,
|
||||
(char**) &create_schema_string, (char**) &create_schema_string, 0, GET_STR,
|
||||
REQUIRED_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"csv", OPT_SLAP_CSV,
|
||||
"Generate CSV output to named file or to stdout if no file is named.",
|
||||
|
@ -590,7 +590,7 @@ static struct my_option my_long_options[] =
|
|||
0, 0, 0, GET_DISABLED, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#else
|
||||
{"debug", '#', "Output debug log. Often this is 'd:t:o,filename'.",
|
||||
&default_dbug_option, &default_dbug_option, 0, GET_STR,
|
||||
(char**) &default_dbug_option, (char**) &default_dbug_option, 0, GET_STR,
|
||||
OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#endif
|
||||
{"debug-check", OPT_DEBUG_CHECK, "Check memory and open file usage at exit.",
|
||||
|
@ -600,7 +600,7 @@ static struct my_option my_long_options[] =
|
|||
&debug_info_flag, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"delimiter", 'F',
|
||||
"Delimiter to use in SQL statements supplied in file or command line.",
|
||||
&delimiter, &delimiter, 0, GET_STR, REQUIRED_ARG,
|
||||
(char**) &delimiter, (char**) &delimiter, 0, GET_STR, REQUIRED_ARG,
|
||||
0, 0, 0, 0, 0, 0},
|
||||
{"detach", OPT_SLAP_DETACH,
|
||||
"Detach (close and reopen) connections after X number of requests.",
|
||||
|
@ -618,11 +618,11 @@ static struct my_option my_long_options[] =
|
|||
&iterations, 0, GET_UINT, REQUIRED_ARG, 1, 0, 0, 0, 0, 0},
|
||||
{"number-char-cols", 'x',
|
||||
"Number of VARCHAR columns to create in table if specifying --auto-generate-sql.",
|
||||
&num_char_cols_opt, &num_char_cols_opt, 0, GET_STR, REQUIRED_ARG,
|
||||
(char**) &num_char_cols_opt, (char**) &num_char_cols_opt, 0, GET_STR, REQUIRED_ARG,
|
||||
0, 0, 0, 0, 0, 0},
|
||||
{"number-int-cols", 'y',
|
||||
"Number of INT columns to create in table if specifying --auto-generate-sql.",
|
||||
&num_int_cols_opt, &num_int_cols_opt, 0, GET_STR, REQUIRED_ARG,
|
||||
(char**) &num_int_cols_opt, (char**) &num_int_cols_opt, 0, GET_STR, REQUIRED_ARG,
|
||||
0, 0, 0, 0, 0, 0},
|
||||
{"number-of-queries", OPT_MYSQL_NUMBER_OF_QUERY,
|
||||
"Limit each client to this number of queries (this is not exact).",
|
||||
|
|
|
@ -5825,7 +5825,7 @@ int read_command(struct st_command** command_ptr)
|
|||
(struct st_command*) my_malloc(sizeof(*command),
|
||||
MYF(MY_WME|MY_ZEROFILL))) ||
|
||||
insert_dynamic(&q_lines, (uchar*) &command))
|
||||
die(NullS);
|
||||
die("Out of memory");
|
||||
command->type= Q_UNKNOWN;
|
||||
|
||||
read_command_buf[0]= 0;
|
||||
|
@ -6322,7 +6322,7 @@ void init_win_path_patterns()
|
|||
}
|
||||
|
||||
if (insert_dynamic(&patterns, (uchar*) &p))
|
||||
die(NullS);
|
||||
die("Out of memory");
|
||||
|
||||
DBUG_PRINT("info", ("p: %s", p));
|
||||
while (*p)
|
||||
|
@ -9402,8 +9402,7 @@ REPLACE *init_replace(char * *from, char * *to,uint count,
|
|||
for (i=1 ; i <= found_sets ; i++)
|
||||
{
|
||||
pos=from[found_set[i-1].table_offset];
|
||||
rep_str[i].found= !bcmp((const uchar*) pos,
|
||||
(const uchar*) "\\^", 3) ? 2 : 1;
|
||||
rep_str[i].found= !memcmp(pos, "\\^", 3) ? 2 : 1;
|
||||
rep_str[i].replace_string=to_array[found_set[i-1].table_offset];
|
||||
rep_str[i].to_offset=found_set[i-1].found_offset-start_at_word(pos);
|
||||
rep_str[i].from_offset=found_set[i-1].found_offset-replace_len(pos)+
|
||||
|
@ -9531,8 +9530,8 @@ void copy_bits(REP_SET *to,REP_SET *from)
|
|||
|
||||
int cmp_bits(REP_SET *set1,REP_SET *set2)
|
||||
{
|
||||
return bcmp((uchar*) set1->bits,(uchar*) set2->bits,
|
||||
sizeof(uint) * set1->size_of_bits);
|
||||
return memcmp(set1->bits, set2->bits,
|
||||
sizeof(uint) * set1->size_of_bits);
|
||||
}
|
||||
|
||||
|
||||
|
@ -9601,17 +9600,15 @@ int find_found(FOUND_SET *found_set,uint table_offset, int found_offset)
|
|||
|
||||
uint start_at_word(char * pos)
|
||||
{
|
||||
return (((!bcmp((const uchar*) pos, (const uchar*) "\\b",2) && pos[2]) ||
|
||||
!bcmp((const uchar*) pos, (const uchar*) "\\^", 2)) ? 1 : 0);
|
||||
return (((!memcmp(pos, "\\b",2) && pos[2]) ||
|
||||
!memcmp(pos, "\\^", 2)) ? 1 : 0);
|
||||
}
|
||||
|
||||
uint end_of_word(char * pos)
|
||||
{
|
||||
char * end=strend(pos);
|
||||
return ((end > pos+2 && !bcmp((const uchar*) end-2,
|
||||
(const uchar*) "\\b", 2)) ||
|
||||
(end >= pos+2 && !bcmp((const uchar*) end-2,
|
||||
(const uchar*) "\\$",2))) ? 1 : 0;
|
||||
return ((end > pos+2 && !memcmp(end-2, "\\b", 2)) ||
|
||||
(end >= pos+2 && !memcmp(end-2, "\\$",2))) ? 1 : 0;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
|
|
@ -19,6 +19,3 @@
|
|||
|
||||
SUBDIRS= @readline_basedir@
|
||||
DIST_SUBDIRS= libedit readline
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -31,7 +31,7 @@ noinst_HEADERS = readline.h chardefs.h keymaps.h \
|
|||
|
||||
EXTRA_DIST= emacs_keymap.c vi_keymap.c
|
||||
|
||||
DEFS = -DMYSQL_CLIENT_NO_THREADS -DHAVE_CONFIG_H -DNO_KILL_INTR
|
||||
DEFS = -DMYSQL_CLIENT_NO_THREADS -DHAVE_CONFIG_H -DNO_KILL_INTR -D_GNU_SOURCE=1
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -318,7 +318,9 @@ _rl_input_available ()
|
|||
return (_kbhit ());
|
||||
#endif
|
||||
|
||||
#if !defined (HAVE_SELECT)
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
int
|
||||
|
|
64
config/ac-macros/maintainer.m4
Normal file
64
config/ac-macros/maintainer.m4
Normal file
|
@ -0,0 +1,64 @@
|
|||
#
|
||||
# Control aspects of the development environment which are
|
||||
# specific to MySQL maintainers and developers.
|
||||
#
|
||||
AC_DEFUN([MY_MAINTAINER_MODE], [
|
||||
AC_MSG_CHECKING([whether to enable the maintainer-specific development environment])
|
||||
AC_ARG_ENABLE([mysql-maintainer-mode],
|
||||
[AS_HELP_STRING([--enable-mysql-maintainer-mode],
|
||||
[Enable a MySQL maintainer-specific development environment])],
|
||||
[USE_MYSQL_MAINTAINER_MODE=$enableval],
|
||||
[USE_MYSQL_MAINTAINER_MODE=no])
|
||||
AC_MSG_RESULT([$USE_MYSQL_MAINTAINER_MODE])
|
||||
])
|
||||
|
||||
# Set warning options required under maintainer mode.
|
||||
AC_DEFUN([MY_MAINTAINER_MODE_WARNINGS], [
|
||||
# Setup GCC warning options.
|
||||
AS_IF([test "$GCC" = "yes"], [
|
||||
C_WARNINGS="-Wall -Wextra -Wunused -Wwrite-strings -Werror"
|
||||
CXX_WARNINGS="${C_WARNINGS} -Wno-unused-parameter"
|
||||
])
|
||||
|
||||
# Test whether the warning options work.
|
||||
# Test C options
|
||||
AS_IF([test -n "$C_WARNINGS"], [
|
||||
save_CFLAGS="$CFLAGS"
|
||||
AC_MSG_CHECKING([whether to use C warning options ${C_WARNINGS}])
|
||||
AC_LANG_PUSH(C)
|
||||
CFLAGS="$CFLAGS ${C_WARNINGS}"
|
||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], [myac_c_warning_flags=yes],
|
||||
[myac_c_warning_flags=no])
|
||||
AC_LANG_POP()
|
||||
AC_MSG_RESULT([$myac_c_warning_flags])
|
||||
CFLAGS="$save_CFLAGS"
|
||||
])
|
||||
|
||||
# Test C++ options
|
||||
AS_IF([test -n "$CXX_WARNINGS"], [
|
||||
save_CXXFLAGS="$CXXFLAGS"
|
||||
AC_MSG_CHECKING([whether to use C++ warning options ${CXX_WARNINGS}])
|
||||
AC_LANG_PUSH(C++)
|
||||
CXXFLAGS="$CXXFLAGS ${CXX_WARNINGS}"
|
||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], [myac_cxx_warning_flags=yes],
|
||||
[myac_cxx_warning_flags=no])
|
||||
AC_LANG_POP()
|
||||
AC_MSG_RESULT([$myac_cxx_warning_flags])
|
||||
CXXFLAGS="$save_CXXFLAGS"
|
||||
])
|
||||
|
||||
# Set compile flag variables.
|
||||
AS_IF([test "$myac_c_warning_flags" = "yes"], [
|
||||
AM_CFLAGS="${AM_CFLAGS} ${C_WARNINGS}"
|
||||
AC_SUBST([AM_CFLAGS])])
|
||||
AS_IF([test "$myac_cxx_warning_flags" = "yes"], [
|
||||
AM_CXXFLAGS="${AM_CXXFLAGS} ${CXX_WARNINGS}"
|
||||
AC_SUBST([AM_CXXFLAGS])])
|
||||
])
|
||||
|
||||
|
||||
# Set compiler flags required under maintainer mode.
|
||||
AC_DEFUN([MY_MAINTAINER_MODE_SETUP], [
|
||||
AS_IF([test "$USE_MYSQL_MAINTAINER_MODE" = "yes"],
|
||||
[MY_MAINTAINER_MODE_WARNINGS])
|
||||
])
|
16
configure.in
16
configure.in
|
@ -12,7 +12,7 @@ dnl
|
|||
dnl When changing the major version number please also check the switch
|
||||
dnl statement in mysqlbinlog::check_master_version(). You may also need
|
||||
dnl to update version.c in ndb.
|
||||
AC_INIT([MariaDB Server], [5.1.49-MariaDB], [], [mysql])
|
||||
AC_INIT([MariaDB Server], [5.1.50-MariaDB], [], [mysql])
|
||||
|
||||
AC_CONFIG_SRCDIR([sql/mysqld.cc])
|
||||
AC_CANONICAL_SYSTEM
|
||||
|
@ -65,6 +65,7 @@ MYSQL_TCP_PORT_DEFAULT=3306
|
|||
MYSQL_UNIX_ADDR_DEFAULT="/tmp/mysql.sock"
|
||||
|
||||
dnl Include m4
|
||||
sinclude(config/ac-macros/maintainer.m4)
|
||||
sinclude(config/ac-macros/alloca.m4)
|
||||
sinclude(config/ac-macros/check_cpu.m4)
|
||||
sinclude(config/ac-macros/character_sets.m4)
|
||||
|
@ -103,6 +104,8 @@ AC_SUBST(SHARED_LIB_MAJOR_VERSION)
|
|||
AC_SUBST(SHARED_LIB_VERSION)
|
||||
AC_SUBST(AVAILABLE_LANGUAGES)
|
||||
|
||||
# Whether the maintainer mode should be enabled.
|
||||
MY_MAINTAINER_MODE
|
||||
|
||||
# Canonicalize the configuration name.
|
||||
|
||||
|
@ -2892,7 +2895,13 @@ do
|
|||
done
|
||||
AC_SUBST(sql_union_dirs)
|
||||
|
||||
# Some useful subst
|
||||
#
|
||||
# Setup maintainer mode options by the end to not disturb
|
||||
# system and other checks.
|
||||
#
|
||||
MY_MAINTAINER_MODE_SETUP
|
||||
|
||||
# Some usefull subst
|
||||
AC_SUBST(CC)
|
||||
AC_SUBST(GXX)
|
||||
|
||||
|
@ -2917,7 +2926,8 @@ fi
|
|||
|
||||
AC_CONFIG_FILES(Makefile extra/Makefile mysys/Makefile dnl
|
||||
unittest/Makefile unittest/mytap/Makefile unittest/mytap/t/Makefile dnl
|
||||
unittest/mysys/Makefile unittest/examples/Makefile dnl
|
||||
unittest/mysys/Makefile unittest/strings/Makefile dnl
|
||||
unittest/examples/Makefile dnl
|
||||
strings/Makefile regex/Makefile storage/Makefile dnl
|
||||
man/Makefile BUILD/Makefile vio/Makefile dnl
|
||||
libmysql/Makefile libmysql_r/Makefile client/Makefile dnl
|
||||
|
|
|
@ -65,6 +65,3 @@ output5.r: factorial
|
|||
# a hack to have executable in builddir, not in srcdir
|
||||
tests-t: tests-t.pl
|
||||
cp -f $(srcdir)/tests-t.pl ./tests-t
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -55,6 +55,3 @@ EXTRA_DIST = CMakeLists.txt
|
|||
|
||||
perror.o: perror.c
|
||||
$(COMPILE) @ndbcluster_includes@ $(LM_CFLAGS) -c $<
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -640,9 +640,9 @@ static struct message *find_message(struct errors *err, const char *lang,
|
|||
static ha_checksum checksum_format_specifier(const char* msg)
|
||||
{
|
||||
ha_checksum chksum= 0;
|
||||
const char* p= msg;
|
||||
const char* start= 0;
|
||||
int num_format_specifiers= 0;
|
||||
const uchar* p= (const uchar*) msg;
|
||||
const uchar* start= NULL;
|
||||
uint32 num_format_specifiers= 0;
|
||||
while (*p)
|
||||
{
|
||||
|
||||
|
@ -832,7 +832,6 @@ static struct message *parse_message_string(struct message *new_message,
|
|||
static struct errors *parse_error_string(char *str, int er_count)
|
||||
{
|
||||
struct errors *new_error;
|
||||
char *start;
|
||||
DBUG_ENTER("parse_error_string");
|
||||
DBUG_PRINT("enter", ("str: %s", str));
|
||||
|
||||
|
@ -843,7 +842,6 @@ static struct errors *parse_error_string(char *str, int er_count)
|
|||
DBUG_RETURN(0); /* OOM: Fatal error */
|
||||
|
||||
/* getting the error name */
|
||||
start= str;
|
||||
str= skip_delimiters(str);
|
||||
|
||||
if (!(new_error->er_name= get_word(&str)))
|
||||
|
|
|
@ -55,8 +55,8 @@ static struct my_option my_long_options[] =
|
|||
{"debug", '#', "This is a non-debug version. Catch this and exit",
|
||||
0,0, 0, GET_DISABLED, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#else
|
||||
{"debug", '#', "Output debug log", &default_dbug_option,
|
||||
&default_dbug_option, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
{"debug", '#', "Output debug log", (char**) &default_dbug_option,
|
||||
(char**) &default_dbug_option, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0},
|
||||
#endif
|
||||
{"defaults-file", 'c', "Like --config-file, except: if first option, "
|
||||
"then read this file only, do not read global or per-user config "
|
||||
|
|
|
@ -649,7 +649,7 @@ static REPLACE *init_replace(char * *from, char * *to,uint count,
|
|||
for (i=1 ; i <= found_sets ; i++)
|
||||
{
|
||||
pos=from[found_set[i-1].table_offset];
|
||||
rep_str[i].found= (my_bool) (!bcmp(pos,"\\^",3) ? 2 : 1);
|
||||
rep_str[i].found= (my_bool) (!memcmp(pos,"\\^",3) ? 2 : 1);
|
||||
rep_str[i].replace_string=to_array[found_set[i-1].table_offset];
|
||||
rep_str[i].to_offset=found_set[i-1].found_offset-start_at_word(pos);
|
||||
rep_str[i].from_offset=found_set[i-1].found_offset-replace_len(pos)+
|
||||
|
@ -777,8 +777,8 @@ static void copy_bits(REP_SET *to,REP_SET *from)
|
|||
|
||||
static int cmp_bits(REP_SET *set1,REP_SET *set2)
|
||||
{
|
||||
return bcmp((uchar*) set1->bits,(uchar*) set2->bits,
|
||||
sizeof(uint) * set1->size_of_bits);
|
||||
return memcmp(set1->bits, set2->bits,
|
||||
sizeof(uint) * set1->size_of_bits);
|
||||
}
|
||||
|
||||
|
||||
|
@ -850,14 +850,14 @@ static short find_found(FOUND_SET *found_set,uint table_offset,
|
|||
|
||||
static uint start_at_word(char * pos)
|
||||
{
|
||||
return (((!bcmp(pos,"\\b",2) && pos[2]) || !bcmp(pos,"\\^",2)) ? 1 : 0);
|
||||
return (((!memcmp(pos,"\\b",2) && pos[2]) || !memcmp(pos,"\\^",2)) ? 1 : 0);
|
||||
}
|
||||
|
||||
static uint end_of_word(char * pos)
|
||||
{
|
||||
char * end=strend(pos);
|
||||
return ((end > pos+2 && !bcmp(end-2,"\\b",2)) ||
|
||||
(end >= pos+2 && !bcmp(end-2,"\\$",2))) ?
|
||||
return ((end > pos+2 && !memcmp(end-2,"\\b",2)) ||
|
||||
(end >= pos+2 && !memcmp(end-2,"\\$",2))) ?
|
||||
1 : 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -884,21 +884,19 @@ void Alert::Process(input_buffer& input, SSL& ssl)
|
|||
else
|
||||
hmac(ssl, verify, data, aSz, alert, true);
|
||||
|
||||
// read mac and fill
|
||||
// read mac and skip fill
|
||||
int digestSz = ssl.getCrypto().get_digest().get_digestSize();
|
||||
opaque mac[SHA_LEN];
|
||||
input.read(mac, digestSz);
|
||||
|
||||
if (ssl.getSecurity().get_parms().cipher_type_ == block) {
|
||||
int ivExtra = 0;
|
||||
opaque fill;
|
||||
|
||||
if (ssl.isTLSv1_1())
|
||||
ivExtra = ssl.getCrypto().get_cipher().get_blockSize();
|
||||
int padSz = ssl.getSecurity().get_parms().encrypt_size_ - ivExtra -
|
||||
aSz - digestSz;
|
||||
for (int i = 0; i < padSz; i++)
|
||||
fill = input[AUTO];
|
||||
input.set_current(input.get_current() + padSz);
|
||||
}
|
||||
|
||||
// verify
|
||||
|
@ -981,17 +979,17 @@ output_buffer& operator<<(output_buffer& output, const Data& data)
|
|||
void Data::Process(input_buffer& input, SSL& ssl)
|
||||
{
|
||||
int msgSz = ssl.getSecurity().get_parms().encrypt_size_;
|
||||
int pad = 0, padByte = 0;
|
||||
int pad = 0, padSz = 0;
|
||||
int ivExtra = 0;
|
||||
|
||||
if (ssl.getSecurity().get_parms().cipher_type_ == block) {
|
||||
if (ssl.isTLSv1_1()) // IV
|
||||
ivExtra = ssl.getCrypto().get_cipher().get_blockSize();
|
||||
pad = *(input.get_buffer() + input.get_current() + msgSz -ivExtra - 1);
|
||||
padByte = 1;
|
||||
padSz = 1;
|
||||
}
|
||||
int digestSz = ssl.getCrypto().get_digest().get_digestSize();
|
||||
int dataSz = msgSz - ivExtra - digestSz - pad - padByte;
|
||||
int dataSz = msgSz - ivExtra - digestSz - pad - padSz;
|
||||
opaque verify[SHA_LEN];
|
||||
|
||||
const byte* rawData = input.get_buffer() + input.get_current();
|
||||
|
@ -1020,14 +1018,10 @@ void Data::Process(input_buffer& input, SSL& ssl)
|
|||
hmac(ssl, verify, rawData, dataSz, application_data, true);
|
||||
}
|
||||
|
||||
// read mac and fill
|
||||
// read mac and skip fill
|
||||
opaque mac[SHA_LEN];
|
||||
opaque fill;
|
||||
input.read(mac, digestSz);
|
||||
for (int i = 0; i < pad; i++)
|
||||
fill = input[AUTO];
|
||||
if (padByte)
|
||||
fill = input[AUTO];
|
||||
input.set_current(input.get_current() + pad + padSz);
|
||||
|
||||
// verify
|
||||
if (dataSz) {
|
||||
|
@ -2072,11 +2066,9 @@ void Finished::Process(input_buffer& input, SSL& ssl)
|
|||
if (ssl.isTLSv1_1())
|
||||
ivExtra = ssl.getCrypto().get_cipher().get_blockSize();
|
||||
|
||||
opaque fill;
|
||||
int padSz = ssl.getSecurity().get_parms().encrypt_size_ - ivExtra -
|
||||
HANDSHAKE_HEADER - finishedSz - digestSz;
|
||||
for (int i = 0; i < padSz; i++)
|
||||
fill = input[AUTO];
|
||||
input.set_current(input.get_current() + padSz);
|
||||
|
||||
// verify mac
|
||||
if (memcmp(mac, verifyMAC, digestSz)) {
|
||||
|
|
|
@ -51,7 +51,7 @@ public:
|
|||
enum { BLOCK_SIZE = BLOWFISH_BLOCK_SIZE, ROUNDS = 16 };
|
||||
|
||||
Blowfish(CipherDir DIR, Mode MODE)
|
||||
: Mode_BASE(BLOCK_SIZE, DIR, MODE) {}
|
||||
: Mode_BASE(BLOCK_SIZE, DIR, MODE), sbox_(pbox_ + ROUNDS + 2) {}
|
||||
|
||||
#ifdef DO_BLOWFISH_ASM
|
||||
void Process(byte*, const byte*, word32);
|
||||
|
@ -62,8 +62,8 @@ private:
|
|||
static const word32 p_init_[ROUNDS + 2];
|
||||
static const word32 s_init_[4 * 256];
|
||||
|
||||
word32 pbox_[ROUNDS + 2];
|
||||
word32 sbox_[4 * 256];
|
||||
word32 pbox_[ROUNDS + 2 + 4 * 256];
|
||||
word32* sbox_;
|
||||
|
||||
void crypt_block(const word32 in[2], word32 out[2]) const;
|
||||
void AsmProcess(const byte* in, byte* out) const;
|
||||
|
|
|
@ -35,10 +35,7 @@
|
|||
|
||||
// Handler for pure virtual functions
|
||||
namespace __Crun {
|
||||
static void pure_error(void)
|
||||
{
|
||||
assert("Pure virtual method called." == "Aborted");
|
||||
}
|
||||
void pure_error(void);
|
||||
} // namespace __Crun
|
||||
|
||||
#endif // __sun
|
||||
|
@ -54,16 +51,7 @@ extern "C" {
|
|||
#else
|
||||
#include "kernelc.hpp"
|
||||
#endif
|
||||
|
||||
/* Disallow inline __cxa_pure_virtual() */
|
||||
static int __cxa_pure_virtual() __attribute__((noinline, used));
|
||||
static int __cxa_pure_virtual()
|
||||
{
|
||||
// oops, pure virtual called!
|
||||
assert("Pure virtual method called." == "Aborted");
|
||||
return 0;
|
||||
}
|
||||
|
||||
int __cxa_pure_virtual () __attribute__ ((weak));
|
||||
} // extern "C"
|
||||
|
||||
#endif // __GNUC__ > 2
|
||||
|
|
|
@ -185,10 +185,10 @@ Integer AbstractGroup::CascadeScalarMultiply(const Element &x,
|
|||
|
||||
struct WindowSlider
|
||||
{
|
||||
WindowSlider(const Integer &exp, bool fastNegate,
|
||||
WindowSlider(const Integer &expIn, bool fastNegateIn,
|
||||
unsigned int windowSizeIn=0)
|
||||
: exp(exp), windowModulus(Integer::One()), windowSize(windowSizeIn),
|
||||
windowBegin(0), fastNegate(fastNegate), firstTime(true),
|
||||
: exp(expIn), windowModulus(Integer::One()), windowSize(windowSizeIn),
|
||||
windowBegin(0), fastNegate(fastNegateIn), firstTime(true),
|
||||
finished(false)
|
||||
{
|
||||
if (windowSize == 0)
|
||||
|
|
|
@ -185,7 +185,7 @@ void Base64Decoder::Decode()
|
|||
{
|
||||
word32 bytes = coded_.size();
|
||||
word32 plainSz = bytes - ((bytes + (pemLineSz - 1)) / pemLineSz);
|
||||
plainSz = (plainSz * 3 + 3) / 4;
|
||||
plainSz = ((plainSz * 3) / 4) + 3;
|
||||
decoded_.New(plainSz);
|
||||
|
||||
word32 i = 0;
|
||||
|
|
|
@ -283,21 +283,23 @@ DWord() {}
|
|||
word GetHighHalfAsBorrow() const {return 0-halfs_.high;}
|
||||
|
||||
private:
|
||||
struct dword_struct
|
||||
{
|
||||
#ifdef LITTLE_ENDIAN_ORDER
|
||||
word low;
|
||||
word high;
|
||||
#else
|
||||
word high;
|
||||
word low;
|
||||
#endif
|
||||
};
|
||||
|
||||
union
|
||||
{
|
||||
#ifdef TAOCRYPT_NATIVE_DWORD_AVAILABLE
|
||||
dword whole_;
|
||||
#endif
|
||||
struct
|
||||
{
|
||||
#ifdef LITTLE_ENDIAN_ORDER
|
||||
word low;
|
||||
word high;
|
||||
#else
|
||||
word high;
|
||||
word low;
|
||||
#endif
|
||||
} halfs_;
|
||||
struct dword_struct halfs_;
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -1214,20 +1216,24 @@ public:
|
|||
#define AS1(x) #x ";"
|
||||
#define AS2(x, y) #x ", " #y ";"
|
||||
#define AddPrologue \
|
||||
word res; \
|
||||
__asm__ __volatile__ \
|
||||
( \
|
||||
"push %%ebx;" /* save this manually, in case of -fPIC */ \
|
||||
"mov %2, %%ebx;" \
|
||||
"mov %3, %%ebx;" \
|
||||
".intel_syntax noprefix;" \
|
||||
"push ebp;"
|
||||
#define AddEpilogue \
|
||||
"pop ebp;" \
|
||||
".att_syntax prefix;" \
|
||||
"pop %%ebx;" \
|
||||
: \
|
||||
"mov %%eax, %0;" \
|
||||
: "=g" (res) \
|
||||
: "c" (C), "d" (A), "m" (B), "S" (N) \
|
||||
: "%edi", "memory", "cc" \
|
||||
);
|
||||
); \
|
||||
return res;
|
||||
|
||||
#define MulPrologue \
|
||||
__asm__ __volatile__ \
|
||||
( \
|
||||
|
|
|
@ -84,12 +84,23 @@ namespace STL = STL_NAMESPACE;
|
|||
|
||||
}
|
||||
|
||||
#if defined(__ICC) || defined(__INTEL_COMPILER)
|
||||
#ifdef __sun
|
||||
|
||||
// Handler for pure virtual functions
|
||||
namespace __Crun {
|
||||
void pure_error() {
|
||||
assert(!"Aborted: pure virtual method called.");
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(__ICC) || defined(__INTEL_COMPILER) || (__GNUC__ > 2)
|
||||
|
||||
extern "C" {
|
||||
|
||||
int __cxa_pure_virtual() {
|
||||
assert("Pure virtual method called." == "Aborted");
|
||||
assert(!"Aborted: pure virtual method called.");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -176,7 +187,6 @@ word Crop(word value, unsigned int size)
|
|||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
bool HaveCpuId()
|
||||
{
|
||||
#ifdef _MSC_VER
|
||||
|
|
|
@ -160,6 +160,11 @@ inline void err_sys(const char* msg)
|
|||
}
|
||||
|
||||
|
||||
extern "C" {
|
||||
static int PasswordCallBack(char*, int, int, void*);
|
||||
}
|
||||
|
||||
|
||||
static int PasswordCallBack(char* passwd, int sz, int rw, void* userdata)
|
||||
{
|
||||
strncpy(passwd, "12345678", sz);
|
||||
|
|
|
@ -40,7 +40,8 @@ noinst_HEADERS = config-win.h config-netware.h lf.h my_bit.h \
|
|||
my_vle.h my_user.h my_atomic.h atomic/nolock.h \
|
||||
atomic/rwlock.h atomic/x86-gcc.h atomic/generic-msvc.h \
|
||||
atomic/gcc_builtins.h my_libwrap.h my_stacktrace.h \
|
||||
wqueue.h waiting_threads.h
|
||||
wqueue.h waiting_threads.h my_compiler.h
|
||||
|
||||
EXTRA_DIST = mysql.h.pp mysql/plugin.h.pp
|
||||
|
||||
# Remove built files and the symlinked directories
|
||||
|
@ -68,6 +69,3 @@ my_config.h: config.h
|
|||
# generated by configure from the .h.in files
|
||||
dist-hook:
|
||||
$(RM) -f $(distdir)/mysql_version.h $(distdir)/my_config.h
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -33,10 +33,6 @@
|
|||
/* need by my_vsnprintf */
|
||||
#include <stdarg.h>
|
||||
|
||||
#ifdef _AIX
|
||||
#undef HAVE_BCMP
|
||||
#endif
|
||||
|
||||
/* This is needed for the definitions of bzero... on solaris */
|
||||
#if defined(HAVE_STRINGS_H)
|
||||
#include <strings.h>
|
||||
|
@ -114,7 +110,7 @@ extern void bfill(uchar *dst,size_t len,pchar fill);
|
|||
#endif
|
||||
|
||||
#if !defined(bzero) && !defined(HAVE_BZERO)
|
||||
extern void bzero(uchar * dst,size_t len);
|
||||
extern void bzero(void * dst,size_t len);
|
||||
#endif
|
||||
|
||||
#if !defined(bcmp) && !defined(HAVE_BCMP)
|
||||
|
|
|
@ -161,22 +161,6 @@ static inline my_bool bitmap_cmp(const MY_BITMAP *map1, const MY_BITMAP *map2)
|
|||
#define bitmap_set_all(MAP) \
|
||||
(memset((MAP)->bitmap, 0xFF, 4*no_words_in_map((MAP))))
|
||||
|
||||
/**
|
||||
check, set and clear a bit of interest of an integer.
|
||||
|
||||
If the bit is out of range @retval -1. Otherwise
|
||||
bit_is_set @return 0 or 1 reflecting the bit is set or not;
|
||||
bit_do_set @return 1 (bit is set 1)
|
||||
bit_do_clear @return 0 (bit is cleared to 0)
|
||||
*/
|
||||
|
||||
#define bit_is_set(I,B) (sizeof(I) * CHAR_BIT > (B) ? \
|
||||
(((I) & (ULL(1) << (B))) == 0 ? 0 : 1) : -1)
|
||||
#define bit_do_set(I,B) (sizeof(I) * CHAR_BIT > (B) ? \
|
||||
((I) |= (ULL(1) << (B)), 1) : -1)
|
||||
#define bit_do_clear(I,B) (sizeof(I) * CHAR_BIT > (B) ? \
|
||||
((I) &= ~(ULL(1) << (B)), 0) : -1)
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
129
include/my_compiler.h
Normal file
129
include/my_compiler.h
Normal file
|
@ -0,0 +1,129 @@
|
|||
#ifndef MY_COMPILER_INCLUDED
|
||||
#define MY_COMPILER_INCLUDED
|
||||
|
||||
/* Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; version 2 of the License.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
|
||||
|
||||
/**
|
||||
Header for compiler-dependent features.
|
||||
|
||||
Intended to contain a set of reusable wrappers for preprocessor
|
||||
macros, attributes, pragmas, and any other features that are
|
||||
specific to a target compiler.
|
||||
*/
|
||||
|
||||
#include <my_global.h> /* stddef.h offsetof */
|
||||
|
||||
/**
|
||||
Compiler-dependent internal convenience macros.
|
||||
*/
|
||||
|
||||
/* GNU C/C++ */
|
||||
#if defined __GNUC__
|
||||
/* Any after 2.95... */
|
||||
# define MY_ALIGN_EXT
|
||||
|
||||
/* Microsoft Visual C++ */
|
||||
#elif defined _MSC_VER
|
||||
# define MY_ALIGNOF(type) __alignof(type)
|
||||
# define MY_ALIGNED(n) __declspec(align(n))
|
||||
|
||||
/* Oracle Solaris Studio */
|
||||
#elif defined(__SUNPRO_C) || defined(__SUNPRO_CC)
|
||||
# if __SUNPRO_C >= 0x590
|
||||
# define MY_ALIGN_EXT
|
||||
# endif
|
||||
|
||||
/* IBM XL C/C++ */
|
||||
#elif defined __xlC__
|
||||
# if __xlC__ >= 0x0600
|
||||
# define MY_ALIGN_EXT
|
||||
# endif
|
||||
|
||||
/* HP aCC */
|
||||
#elif defined(__HP_aCC) || defined(__HP_cc)
|
||||
# if (__HP_aCC >= 60000) || (__HP_cc >= 60000)
|
||||
# define MY_ALIGN_EXT
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifdef MY_ALIGN_EXT
|
||||
/** Specifies the minimum alignment of a type. */
|
||||
# define MY_ALIGNOF(type) __alignof__(type)
|
||||
/** Determine the alignment requirement of a type. */
|
||||
# define MY_ALIGNED(n) __attribute__((__aligned__((n))))
|
||||
#endif
|
||||
|
||||
/**
|
||||
Generic compiler-dependent features.
|
||||
*/
|
||||
#ifndef MY_ALIGNOF
|
||||
# ifdef __cplusplus
|
||||
template<typename type> struct my_alignof_helper { char m1; type m2; };
|
||||
/* Invalid for non-POD types, but most compilers give the right answer. */
|
||||
# define MY_ALIGNOF(type) offsetof(my_alignof_helper<type>, m2)
|
||||
# else
|
||||
# define MY_ALIGNOF(type) offsetof(struct { char m1; type m2; }, m2)
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/**
|
||||
C++ Type Traits
|
||||
*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
/**
|
||||
Opaque storage with a particular alignment.
|
||||
*/
|
||||
# if defined(MY_ALIGNED)
|
||||
/* Partial specialization used due to MSVC++. */
|
||||
template<size_t alignment> struct my_alignment_imp;
|
||||
template<> struct MY_ALIGNED(1) my_alignment_imp<1> {};
|
||||
template<> struct MY_ALIGNED(2) my_alignment_imp<2> {};
|
||||
template<> struct MY_ALIGNED(4) my_alignment_imp<4> {};
|
||||
template<> struct MY_ALIGNED(8) my_alignment_imp<8> {};
|
||||
template<> struct MY_ALIGNED(16) my_alignment_imp<16> {};
|
||||
/* ... expand as necessary. */
|
||||
# else
|
||||
template<size_t alignment>
|
||||
struct my_alignment_imp { double m1; };
|
||||
# endif
|
||||
|
||||
/**
|
||||
A POD type with a given size and alignment.
|
||||
|
||||
@remark If the compiler does not support a alignment attribute
|
||||
(MY_ALIGN macro), the default alignment of a double is
|
||||
used instead.
|
||||
|
||||
@tparam size The minimum size.
|
||||
@tparam alignment The desired alignment: 1, 2, 4, 8 or 16.
|
||||
*/
|
||||
template <size_t size, size_t alignment>
|
||||
struct my_aligned_storage
|
||||
{
|
||||
union
|
||||
{
|
||||
char data[size];
|
||||
my_alignment_imp<alignment> align;
|
||||
};
|
||||
};
|
||||
|
||||
#endif /* __cplusplus */
|
||||
|
||||
#include <my_attribute.h>
|
||||
|
||||
#endif /* MY_COMPILER_INCLUDED */
|
|
@ -567,31 +567,43 @@ int __void__;
|
|||
#endif
|
||||
#endif /* DONT_DEFINE_VOID */
|
||||
|
||||
#if defined(_lint) || defined(FORCE_INIT_OF_VARS)
|
||||
#define LINT_INIT(var) var=0 /* No uninitialize-warning */
|
||||
/*
|
||||
Try to suppress warning for not initialized variables.
|
||||
|
||||
With gcc when using C, we suppress the uninitialized variable warning
|
||||
without generating code. We can't do this with C++
|
||||
for a g++ bug (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34772).
|
||||
*/
|
||||
|
||||
#if defined(FORCE_INIT_OF_VARS)
|
||||
#define LINT_INIT(var) var= 0
|
||||
#if defined(__cplusplus) || !defined(__GNUC__)
|
||||
#define UNINIT_VAR(x) x= 0
|
||||
#else
|
||||
#define LINT_INIT(var)
|
||||
/* GCC specific self-initialization which inhibits the warning. */
|
||||
#define UNINIT_VAR(x) x= x
|
||||
#endif
|
||||
#else /* !FORCE_INIT_OF_VARS */
|
||||
#define LINT_INIT(var)
|
||||
#if !defined(__cplusplus) && !defined(__GNUC__)
|
||||
/* GCC specific self-initialization which inhibits the warning. */
|
||||
#define UNINIT_VAR(x) x= x
|
||||
#else
|
||||
#define UNINIT_VAR(x) x
|
||||
#endif
|
||||
#endif /* FORCE_INIT_OF_VARS */
|
||||
|
||||
#include <my_valgrind.h>
|
||||
|
||||
#if defined(_lint) || defined(FORCE_INIT_OF_VARS) || defined(HAVE_valgrind)
|
||||
/*
|
||||
The following is to force some unitialized variables to 0 if we are
|
||||
running valgrind. This is needed when the compiler may access the variable
|
||||
even if the value of it is never used.
|
||||
*/
|
||||
#if defined(HAVE_valgrind)
|
||||
#define VALGRIND_OR_LINT_INIT(var) var=0
|
||||
#else
|
||||
#define VALGRIND_OR_LINT_INIT(var)
|
||||
#endif
|
||||
|
||||
/*
|
||||
Suppress uninitialized variable warning without generating code.
|
||||
|
||||
The _cplusplus is a temporary workaround for C++ code pending a fix
|
||||
for a g++ bug (http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34772).
|
||||
*/
|
||||
#if defined(_lint) || defined(FORCE_INIT_OF_VARS) || defined(__cplusplus) || \
|
||||
!defined(__GNUC__)
|
||||
#define UNINIT_VAR(x) x= 0
|
||||
#else
|
||||
#define UNINIT_VAR(x) x= x
|
||||
#define VALGRIND_OR_LINT_INIT(var) LINT_INIT(var)
|
||||
#endif
|
||||
|
||||
/* Define some useful general macros */
|
||||
|
@ -613,8 +625,8 @@ typedef unsigned short ushort;
|
|||
#define test(a) ((a) ? 1 : 0)
|
||||
#define set_if_bigger(a,b) do { if ((a) < (b)) (a)=(b); } while(0)
|
||||
#define set_if_smaller(a,b) do { if ((a) > (b)) (a)=(b); } while(0)
|
||||
#define test_all_bits(a,b) (((a) & (b)) == (b))
|
||||
#define set_bits(type, bit_count) (sizeof(type)*8 <= (bit_count) ? ~(type) 0 : ((((type) 1) << (bit_count)) - (type) 1))
|
||||
#define test_all_bits(a,b) (((a) & (b)) == (b))
|
||||
#define array_elements(A) ((uint) (sizeof(A)/sizeof(A[0])))
|
||||
|
||||
/* Define some general constants */
|
||||
|
@ -635,7 +647,7 @@ typedef unsigned short ushort;
|
|||
#define my_const_cast(A) (A)
|
||||
#endif
|
||||
|
||||
#include <my_attribute.h>
|
||||
#include <my_compiler.h>
|
||||
|
||||
/*
|
||||
Wen using the embedded library, users might run into link problems,
|
||||
|
@ -671,7 +683,7 @@ C_MODE_END
|
|||
# endif
|
||||
#endif
|
||||
|
||||
typedef char my_bool; /* Small bool */
|
||||
typedef char my_bool; /* Small bool; Needed by my_dbug.h */
|
||||
#include <my_dbug.h>
|
||||
|
||||
#define MIN_ARRAY_SIZE 0 /* Zero or One. Gcc allows zero*/
|
||||
|
@ -799,10 +811,10 @@ typedef SOCKET_SIZE_TYPE size_socket;
|
|||
#endif
|
||||
/* get memory in huncs */
|
||||
#define ONCE_ALLOC_INIT (uint) (4096-MALLOC_OVERHEAD)
|
||||
/* Typical record cash */
|
||||
#define RECORD_CACHE_SIZE (uint) (64*1024-MALLOC_OVERHEAD)
|
||||
/* Typical key cash */
|
||||
#define KEY_CACHE_SIZE (uint) (8*1024*1024-MALLOC_OVERHEAD)
|
||||
/* Typical record cache */
|
||||
#define RECORD_CACHE_SIZE (uint) (128*1024-MALLOC_OVERHEAD)
|
||||
/* Typical key cache */
|
||||
#define KEY_CACHE_SIZE (uint) (128L*1024L*1024L-MALLOC_OVERHEAD)
|
||||
/* Default size of a key cache block */
|
||||
#define KEY_CACHE_BLOCK_SIZE (uint) 1024
|
||||
|
||||
|
@ -950,13 +962,11 @@ typedef long long my_ptrdiff_t;
|
|||
#define ALIGN_MAX_UNIT (sizeof(double))
|
||||
/* Size to make adressable obj. */
|
||||
#define ALIGN_PTR(A, t) ((t*) MY_ALIGN((A), sizeof(double)))
|
||||
/* Offset of field f in structure t */
|
||||
#define OFFSET(t, f) ((size_t)(char *)&((t *)0)->f)
|
||||
#define ADD_TO_PTR(ptr,size,type) (type) ((uchar*) (ptr)+size)
|
||||
#define PTR_BYTE_DIFF(A,B) (my_ptrdiff_t) ((uchar*) (A) - (uchar*) (B))
|
||||
|
||||
#define MY_DIV_UP(A, B) (((A) + (B) - 1) / (B))
|
||||
#define MY_ALIGNED_BYTE_ARRAY(N, S, T) T N[MY_DIV_UP(S, sizeof(T))]
|
||||
|
||||
/*
|
||||
Custom version of standard offsetof() macro which can be used to get
|
||||
offsets of members in class for non-POD types (according to the current
|
||||
|
|
|
@ -274,13 +274,14 @@ int sigwait(sigset_t *setp, int *sigp); /* Use our implemention */
|
|||
we want to make sure that no such flags are set.
|
||||
*/
|
||||
#if defined(HAVE_SIGACTION) && !defined(my_sigset)
|
||||
#define my_sigset(A,B) do { struct sigaction l_s; sigset_t l_set; int l_rc; \
|
||||
#define my_sigset(A,B) do { struct sigaction l_s; sigset_t l_set; \
|
||||
IF_DBUG(int l_rc); \
|
||||
DBUG_ASSERT((A) != 0); \
|
||||
sigemptyset(&l_set); \
|
||||
l_s.sa_handler = (B); \
|
||||
l_s.sa_mask = l_set; \
|
||||
l_s.sa_flags = 0; \
|
||||
l_rc= sigaction((A), &l_s, (struct sigaction *) NULL);\
|
||||
IF_DBUG(l_rc=) sigaction((A), &l_s, NULL); \
|
||||
DBUG_ASSERT(l_rc == 0); \
|
||||
} while (0)
|
||||
#elif defined(HAVE_SIGSET) && !defined(my_sigset)
|
||||
|
@ -755,7 +756,7 @@ extern uint thd_lib_detected;
|
|||
The implementation is guaranteed to be thread safe, on all platforms.
|
||||
Note that the calling code should *not* assume the counter is protected
|
||||
by the mutex given, as the implementation of these helpers may change
|
||||
to use my_atomic operations instead.
|
||||
to use atomic operations instead.
|
||||
*/
|
||||
|
||||
/*
|
||||
|
|
|
@ -266,6 +266,7 @@ extern size_t sf_malloc_cur_memory, sf_malloc_max_memory;
|
|||
extern ulong my_default_record_cache_size;
|
||||
extern my_bool NEAR my_disable_locking,NEAR my_disable_async_io,
|
||||
NEAR my_disable_flush_key_blocks, NEAR my_disable_symlinks;
|
||||
extern my_bool my_disable_sync;
|
||||
extern char wild_many,wild_one,wild_prefix;
|
||||
extern const char *charsets_dir;
|
||||
/* from default.c */
|
||||
|
|
|
@ -44,7 +44,9 @@ extern "C" {
|
|||
#endif
|
||||
|
||||
#ifndef _global_h /* If not standard header */
|
||||
#ifndef MYSQL_ABI_CHECK
|
||||
#include <sys/types.h>
|
||||
#endif
|
||||
#ifdef __LCC__
|
||||
#include <winsock2.h> /* For windows */
|
||||
#endif
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
#include <sys/types.h>
|
||||
typedef char my_bool;
|
||||
typedef int my_socket;
|
||||
#include "mysql_version.h"
|
||||
|
|
|
@ -62,10 +62,12 @@ extern const char * NEAR globerrs[]; /* my_error_messages is here */
|
|||
#define EE_UNKNOWN_COLLATION 28
|
||||
#define EE_FILENOTFOUND 29
|
||||
#define EE_FILE_NOT_CLOSED 30
|
||||
#define EE_CANT_CHMOD 31
|
||||
#define EE_CANT_SEEK 32
|
||||
#define EE_CANT_COPY_OWNERSHIP 33
|
||||
#define EE_ERROR_LAST 33 /* Copy last error nr */
|
||||
#define EE_CHANGE_OWNERSHIP 31
|
||||
#define EE_CHANGE_PERMISSIONS 32
|
||||
#define EE_CANT_CHMOD 33
|
||||
#define EE_CANT_SEEK 34
|
||||
#define EE_CANT_COPY_OWNERSHIP 35
|
||||
#define EE_ERROR_LAST 35 /* Copy last error nr */
|
||||
/* Add error numbers before EE_ERROR_LAST and change it accordingly. */
|
||||
|
||||
/* exit codes for all MySQL programs */
|
||||
|
|
|
@ -111,6 +111,3 @@ do-lib-dist:
|
|||
echo ' $$(AR) r $$@ $$?' >>$$dir/Makefile; \
|
||||
gtar cvzf $$dir.tar.gz $$dir; \
|
||||
cd $$dir; gmake
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -4434,6 +4434,7 @@ static my_bool setup_one_fetch_function(MYSQL_BIND *param, MYSQL_FIELD *field)
|
|||
case MYSQL_TYPE_TIME:
|
||||
field->max_length= 15; /* 19:23:48.123456 */
|
||||
param->skip_result= skip_result_with_length;
|
||||
break;
|
||||
case MYSQL_TYPE_DATE:
|
||||
field->max_length= 10; /* 2003-11-11 */
|
||||
param->skip_result= skip_result_with_length;
|
||||
|
|
|
@ -42,6 +42,3 @@ link_sources:
|
|||
done; \
|
||||
done
|
||||
echo timestamp > link_sources
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -232,6 +232,3 @@ link_sources:
|
|||
clean-local:
|
||||
rm -f `echo $(sqlsources) $(libmysqlsources) $(sqlstoragesources) $(storagesources) | sed "s;\.lo;.c;g"`; \
|
||||
rm -f client_settings.h
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -42,7 +42,8 @@ LDADD = @CLIENT_EXTRA_LDFLAGS@ ../libmysqld.a @LIBDL@ $(CXXLDFLAGS) \
|
|||
|
||||
mysqltest_embedded_LINK = $(CXXLINK)
|
||||
nodist_mysqltest_embedded_SOURCES = mysqltest.cc
|
||||
mysqltest_embedded_LDADD = $(LDADD) $(top_builddir)/regex/libregex.a
|
||||
mysqltest_embedded_LDADD = $(LDADD) $(top_builddir)/regex/libregex.a \
|
||||
@MYSQLD_EXTRA_LDFLAGS@
|
||||
|
||||
nodist_mysql_SOURCES = mysql.cc readline.cc completion_hash.cc \
|
||||
my_readline.h sql_string.h completion_hash.h
|
||||
|
|
|
@ -24,6 +24,3 @@ EXTRA_DIST = $(man1_MANS) $(man8_MANS)
|
|||
# "make_win_*" are not needed in Unix binary packages,
|
||||
install-data-hook:
|
||||
rm -f $(DESTDIR)$(mandir)/man1/make_win_*
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -63,13 +63,14 @@ nobase_test_DATA = \
|
|||
lib/My/SafeProcess.pm \
|
||||
lib/My/File/Path.pm \
|
||||
lib/My/SysInfo.pm \
|
||||
lib/My/Suite.pm \
|
||||
lib/My/CoreDump.pm \
|
||||
lib/My/SafeProcess/Base.pm \
|
||||
lib/My/SafeProcess/safe_process.pl
|
||||
|
||||
SUBDIRS = lib/My/SafeProcess
|
||||
|
||||
EXTRA_DIST = README \
|
||||
EXTRA_DIST = README README.suites \
|
||||
$(test_SCRIPTS) \
|
||||
$(nobase_test_DATA)
|
||||
|
||||
|
@ -101,9 +102,10 @@ TEST_DIRS = t r include std_data std_data/parts collections \
|
|||
suite/ndb suite/ndb/t suite/ndb/r \
|
||||
suite/rpl_ndb suite/rpl_ndb/t suite/rpl_ndb/r \
|
||||
suite/parts suite/parts/t suite/parts/r suite/parts/inc \
|
||||
suite/pbxt/t suite/pbxt/r \
|
||||
suite/pbxt/t suite/pbxt/r suite/pbxt \
|
||||
suite/innodb suite/innodb/t suite/innodb/r suite/innodb/include \
|
||||
suite/innodb_plugin suite/innodb_plugin/t suite/innodb_plugin/r suite/innodb_plugin/include \
|
||||
suite/innodb_plugin suite/innodb_plugin/t suite/innodb_plugin/r \
|
||||
suite/innodb_plugin/include \
|
||||
suite/percona \
|
||||
suite/engines suite/engines/funcs suite/engines/iuds suite/engines/rr_trx \
|
||||
suite/engines/funcs/r suite/engines/funcs/t suite/engines/iuds/r \
|
||||
|
@ -145,6 +147,3 @@ mtr:
|
|||
mysql-test-run:
|
||||
$(RM) -f mysql-test-run
|
||||
$(LN_S) mysql-test-run.pl mysql-test-run
|
||||
|
||||
# Don't update the files from bitkeeper
|
||||
%::SCCS/s.%
|
||||
|
|
|
@ -18,7 +18,7 @@ the test suite expects you to provide the names of the tests to run.
|
|||
For example, here is the command to run the "alias" and "analyze" tests
|
||||
with an external server:
|
||||
|
||||
mysql-test-run --extern alias analyze
|
||||
mysql-test-run --extern socket=/tmp/mysql.sock alias analyze
|
||||
|
||||
To match your setup, you might also need to provide --socket, --user, and
|
||||
other relevant options.
|
||||
|
|
145
mysql-test/README.suites
Normal file
145
mysql-test/README.suites
Normal file
|
@ -0,0 +1,145 @@
|
|||
These are the assorted notes that will be turned into a manual eventually.
|
||||
|
||||
==========================
|
||||
Tests are organized in suites.
|
||||
A "suite" is a subdirectory inside, one of,
|
||||
|
||||
<basedir>/mysql-test/suite
|
||||
<basedir>/mysql-test
|
||||
<basedir>/share/mysql-test/suite
|
||||
<basedir>/share/mysql-test
|
||||
<basedir>/share/mysql/mysql-test/suite
|
||||
<basedir>/share/mysql/mysql-test
|
||||
<basedir>/storage/*/mysql-test-suites
|
||||
|
||||
This is supposed to cover running mtr from a source directory and installed.
|
||||
|
||||
==========================
|
||||
A suite contains *.test and *.result files. They can be in the t/ and r/
|
||||
subdirectories under the suitedir or directly in the suitedir
|
||||
(that is suitedir/t/*.test or suitedir/*.test, same for *.result))
|
||||
|
||||
==========================
|
||||
A suite can contain a suite.opt file - at the same location where .test files
|
||||
are or in the suite directory. As usual, the .opt file can use $-substitutions
|
||||
for the environment variables.
|
||||
|
||||
Usually, using my.cnf template (see below) is preferrable.
|
||||
|
||||
But command line options (.opt files and combinations file) get special
|
||||
treatment - they can have special options that affect mtr behavior. cnf
|
||||
files cannot. Special options are
|
||||
--timezone, --plugin-load, --result-file, --config-file-template,
|
||||
--default-time-zone, --force-restart
|
||||
|
||||
==========================
|
||||
A suite can have suite.pm file in the suitedir. It must declare a
|
||||
package that inherits from My::Suite.
|
||||
|
||||
The suite.pm needs to have @ISA=qw(My::Suite) and it must end
|
||||
with bless {}; - that is it must return an object of that class.
|
||||
It can also return a string - in this case all tests in the suite
|
||||
will be skipped, with this string being printed as a reason.
|
||||
|
||||
A suite class can define config_files() and servers() methods.
|
||||
|
||||
A config_files method returns a list of additional config files (besides
|
||||
my.cnf), that this suite needs to be created. For every file it specifies
|
||||
a function that will create it, when given a My::Config object. For example:
|
||||
|
||||
sub config_files { ( 'config.ini' => \&write_ini,
|
||||
'new.conf' => \&do_new_conf ) }
|
||||
|
||||
A servers method returns a list of processes that needs to be started for
|
||||
this suite. A process is specified as a pair (regex, hash). A regex must
|
||||
match a section in the my.cnf template (for example, qr/mysqld\./ corresponds
|
||||
to all mysqld processes), a hash contains these options:
|
||||
|
||||
SORT => a number, processes are started in the order of increasing SORT
|
||||
values (and stopped in the reverse order). mysqld has number 300.
|
||||
START => a function to start a process. It takes two arguments,
|
||||
My::Config::Group and My::Test. If START is undefined the process
|
||||
will not be started.
|
||||
WAIT => a function waits for the process to be started. It takes
|
||||
My::Config::Group as an argument. Internallys mtr first invokes
|
||||
START for all processes, then WAIT for all started processes.
|
||||
|
||||
example: sub servers { ( qr/^foo$/ => { SORT => 200,
|
||||
START => \&start_foo,
|
||||
WAIT => \&wait_foo } ) }
|
||||
|
||||
See sphinx suite for an example.
|
||||
|
||||
==========================
|
||||
A suite can have my.cnf template file in the suitedir.
|
||||
A my.cnf template uses a normal my.cnf syntax - groups, options,
|
||||
and values - with templating extensions. They are
|
||||
|
||||
* There can be groups with non-standard names, not used by mysqld.
|
||||
These groups may be used by the suite.pm file somehow.
|
||||
For example, they can be written to the additional config files.
|
||||
See sphinx suite for an example.
|
||||
|
||||
* There can be ENV group. It sets values for the environment variables.
|
||||
|
||||
* Values can refer to each other - they will be expanded as needed.
|
||||
A reference to a value of an option looks like @groupname.optionname.
|
||||
For example
|
||||
|
||||
[mysqld.2]
|
||||
master-port= @mysqld.1.port
|
||||
|
||||
it sets the master-port in the mysqld.2 group to the value of
|
||||
port in the mysqld.1 group.
|
||||
|
||||
* An option name may start from '#'. In the resulting my.cnf it will look
|
||||
like a comment, but it still can be referred to. For example:
|
||||
|
||||
[example]
|
||||
#foo = localhost:@mysqld.1.port
|
||||
bar = http://@example.#foo/index.html
|
||||
|
||||
* There are two special - in this regard - groups.
|
||||
|
||||
Via the ENV group one can refer to any environment variable, not only
|
||||
to values in the [ENV] group of my.cnf file.
|
||||
|
||||
Via the OPT group one can refer to special values:
|
||||
@OPT.vardir - a path to vardir
|
||||
@OPT.port - a new port number is reserved out of the pool. It will not
|
||||
match any other port number used by this test run.
|
||||
See sphinx suite for an example.
|
||||
|
||||
Most probably a suite my.cnf will need to start from
|
||||
|
||||
!include include/default_my.cnf
|
||||
|
||||
and then modify the configuration as necessary.
|
||||
|
||||
==========================
|
||||
A suite can have combinations file in the suitedir. It uses my.cnf syntax
|
||||
but it cannot use @-substitutions. Instead, it can use $-substitutions for
|
||||
the environment variables. Because the combination options will not be
|
||||
merged to a my.cnf, but will be added to the command line. Example:
|
||||
|
||||
[conf1]
|
||||
opt1=val1
|
||||
|
||||
[conf2]
|
||||
opt1=val2
|
||||
opt2=$HAVE_SOMETHING
|
||||
|
||||
Such a file will cause every test from the suite to be run twice - once
|
||||
with mysqld using --opt1=val1 and the other one with mysqld using
|
||||
--opt1=val2 --opt2=$HAVE_SOMETHING
|
||||
|
||||
One can limit mtr run to a subset of combinations by setting environment
|
||||
variable SUITENAME_COMBINATIONS to the ':'-separated set of combination
|
||||
names. E.g.
|
||||
|
||||
RPL_COMBINATIONS=mix:row ./mtr --suite rpl
|
||||
|
||||
See innodb_plugin suite for an example of how suite.pm may set this variable
|
||||
to exclude unsupported configurations.
|
||||
==========================
|
||||
|
|
@ -725,9 +725,9 @@ call p_verify_status_increment(4, 4, 4, 4);
|
|||
alter table t3 add column (b int);
|
||||
call p_verify_status_increment(2, 0, 2, 0);
|
||||
alter table t3 rename t4;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
rename table t4 to t3;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
truncate table t3;
|
||||
call p_verify_status_increment(4, 4, 4, 4);
|
||||
create view v1 as select * from t2;
|
||||
|
|
|
@ -6,9 +6,6 @@
|
|||
# Run the master.sh script before starting this process
|
||||
#!run-master-sh
|
||||
|
||||
log-bin= master-bin
|
||||
|
||||
|
||||
[mysqlbinlog]
|
||||
disable-force-if-open
|
||||
|
||||
|
|
|
@ -13,9 +13,10 @@ key_buffer_size= 1M
|
|||
sort_buffer= 256K
|
||||
max_heap_table_size= 1M
|
||||
|
||||
loose-skip-innodb
|
||||
loose-skip-pbxt
|
||||
|
||||
loose-innodb_data_file_path= ibdata1:10M:autoextend
|
||||
|
||||
slave-net-timeout=120
|
||||
|
||||
log-bin=mysqld-bin
|
||||
|
||||
|
|
|
@ -64,17 +64,13 @@ let $_diff_table=$diff_table_2;
|
|||
let $_diff_i=2;
|
||||
while ($_diff_i) {
|
||||
|
||||
# Parse out any leading "master:" or "slave:" from the table
|
||||
# specification and connect the appropriate server.
|
||||
let $_diff_conn_master=`SELECT SUBSTR('$_diff_table', 1, 7) = 'master:'`;
|
||||
if ($_diff_conn_master) {
|
||||
let $_diff_table=`SELECT SUBSTR('$_diff_table', 8)`;
|
||||
connection master;
|
||||
}
|
||||
let $_diff_conn_slave=`SELECT SUBSTR('$_diff_table', 1, 6) = 'slave:'`;
|
||||
if ($_diff_conn_slave) {
|
||||
let $_diff_table=`SELECT SUBSTR('$_diff_table', 7)`;
|
||||
connection slave;
|
||||
# Parse out any leading "master:" or "slave:" from the table specification
|
||||
# and connect the appropriate server.
|
||||
let $_pos= `SELECT LOCATE(':', '$_diff_table')`;
|
||||
let $_diff_conn=`SELECT SUBSTR('$_diff_table', 1, $_pos-1)`;
|
||||
if (`SELECT 'XX$_diff_conn' <> 'XX'`) {
|
||||
let $_diff_table=`SELECT SUBSTR('$_diff_table', $_pos+1)`;
|
||||
connection $_diff_conn;
|
||||
}
|
||||
|
||||
# Sanity-check the input.
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
--disable_query_log
|
||||
--require r/true.require
|
||||
select (support = 'YES' or support = 'DEFAULT') as `TRUE` from information_schema.engines where engine = 'archive';
|
||||
--enable_query_log
|
||||
if (!`SELECT count(*) FROM information_schema.engines WHERE
|
||||
(support = 'YES' OR support = 'DEFAULT') AND
|
||||
engine = 'archive'`){
|
||||
skip Need archive engine;
|
||||
}
|
||||
|
|
2
mysql-test/include/have_archive.opt
Normal file
2
mysql-test/include/have_archive.opt
Normal file
|
@ -0,0 +1,2 @@
|
|||
--loose-archive
|
||||
--plugin-load=$HA_ARCHIVE_SO
|
1
mysql-test/include/have_binlog_format_mixed.opt
Normal file
1
mysql-test/include/have_binlog_format_mixed.opt
Normal file
|
@ -0,0 +1 @@
|
|||
--binlog-format=mixed
|
1
mysql-test/include/have_binlog_format_row.opt
Normal file
1
mysql-test/include/have_binlog_format_row.opt
Normal file
|
@ -0,0 +1 @@
|
|||
--binlog-format=row
|
2
mysql-test/include/have_binlog_format_statement.opt
Normal file
2
mysql-test/include/have_binlog_format_statement.opt
Normal file
|
@ -0,0 +1,2 @@
|
|||
--binlog-format=statement
|
||||
|
2
mysql-test/include/have_blackhole.opt
Normal file
2
mysql-test/include/have_blackhole.opt
Normal file
|
@ -0,0 +1,2 @@
|
|||
--loose-blackhole
|
||||
--plugin-load=$HA_BLACKHOLE_SO
|
|
@ -1,4 +0,0 @@
|
|||
disable_query_log;
|
||||
--require r/true.require
|
||||
select (support = 'YES' or support = 'DEFAULT') as `TRUE` from information_schema.engines where engine = 'example';
|
||||
enable_query_log;
|
|
@ -1,4 +1,5 @@
|
|||
disable_query_log;
|
||||
--require r/true.require
|
||||
select (support = 'YES' or support = 'DEFAULT' or support = 'ENABLED') as `TRUE` from information_schema.engines where engine = 'innodb';
|
||||
enable_query_log;
|
||||
if (!`SELECT count(*) FROM information_schema.engines WHERE
|
||||
(support = 'YES' OR support = 'DEFAULT') AND
|
||||
engine = 'innodb'`){
|
||||
skip Needs innodb engine;
|
||||
}
|
||||
|
|
2
mysql-test/include/have_innodb.opt
Normal file
2
mysql-test/include/have_innodb.opt
Normal file
|
@ -0,0 +1,2 @@
|
|||
--loose-innodb
|
||||
--plugin-load=$HA_XTRADB_SO
|
|
@ -1,4 +1,5 @@
|
|||
disable_query_log;
|
||||
--require r/true.require
|
||||
SELECT (plugin_library LIKE 'ha_innodb_plugin%' OR plugin_description LIKE '%xtradb%') AS `TRUE` FROM information_schema.plugins WHERE LOWER(plugin_name) = 'innodb' AND LOWER(plugin_status) = 'active';
|
||||
enable_query_log;
|
||||
if (!`SELECT COUNT(*) FROM INFORMATION_SCHEMA.PLUGINS
|
||||
WHERE PLUGIN_NAME = 'innodb' AND PLUGIN_STATUS = 'active' AND
|
||||
(PLUGIN_LIBRARY LIKE 'ha_innodb_plugin%' OR PLUGIN_DESCRIPTION LIKE '%xtradb%')`) {
|
||||
skip Need InnoDB plugin or XtraDB;
|
||||
}
|
||||
|
|
1
mysql-test/include/have_log_bin-master.opt
Normal file
1
mysql-test/include/have_log_bin-master.opt
Normal file
|
@ -0,0 +1 @@
|
|||
--log-bin=master-bin
|
1
mysql-test/include/have_log_bin-slave.opt
Normal file
1
mysql-test/include/have_log_bin-slave.opt
Normal file
|
@ -0,0 +1 @@
|
|||
--log-bin=slave-bin
|
|
@ -6,6 +6,8 @@
|
|||
#
|
||||
# source include/have_log_bin.inc;
|
||||
|
||||
source include/not_embedded.inc;
|
||||
|
||||
-- require r/have_log_bin.require
|
||||
disable_query_log;
|
||||
show variables like 'log_bin';
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
disable_query_log;
|
||||
--require r/true.require
|
||||
select (support = 'YES' or support = 'DEFAULT') as `TRUE` from information_schema.engines where engine = 'pbxt';
|
||||
enable_query_log;
|
||||
if (!`SELECT count(*) FROM information_schema.engines WHERE
|
||||
(support = 'YES' OR support = 'DEFAULT') AND
|
||||
engine = 'pbxt'`){
|
||||
skip Need PBXT engine;
|
||||
}
|
||||
|
|
1
mysql-test/include/have_pbxt.opt
Normal file
1
mysql-test/include/have_pbxt.opt
Normal file
|
@ -0,0 +1 @@
|
|||
--loose-pbxt
|
35
mysql-test/include/rpl_diff_tables.inc
Normal file
35
mysql-test/include/rpl_diff_tables.inc
Normal file
|
@ -0,0 +1,35 @@
|
|||
# #############################################################################
|
||||
# Check whether the given table is consistent between different master and
|
||||
# slaves
|
||||
#
|
||||
# Usage:
|
||||
# --let $diff_table= test.t1
|
||||
# --let $diff_server_list= master, slave, slave2
|
||||
# --source include/rpl_diff_tables.inc
|
||||
# #############################################################################
|
||||
|
||||
if (`SELECT "XX$diff_table" = "XX"`)
|
||||
{
|
||||
--die diff_table is null.
|
||||
}
|
||||
|
||||
--let $_servers= master, slave
|
||||
if (`SELECT "XX$diff_server_list" <> "XX"`)
|
||||
{
|
||||
--let $_servers= $diff_server_list
|
||||
}
|
||||
|
||||
--let $_master= `SELECT SUBSTRING_INDEX('$_servers', ',', 1)`
|
||||
--let $_servers= `SELECT LTRIM(SUBSTRING('$_servers', LENGTH('$_master') + 2))`
|
||||
connection $_master;
|
||||
while (`SELECT "XX$_servers" <> "XX"`)
|
||||
{
|
||||
--let $_slave= `SELECT SUBSTRING_INDEX('$_servers', ',', 1)`
|
||||
--let $_servers= `SELECT LTRIM(SUBSTRING('$_servers', LENGTH('$_slave') + 2))`
|
||||
|
||||
--sync_slave_with_master $_slave
|
||||
--let $diff_table_1= $_master:$diff_table
|
||||
--let $diff_table_2= $_slave:$diff_table
|
||||
--source include/diff_tables.inc
|
||||
connection $_slave;
|
||||
}
|
|
@ -6,7 +6,6 @@ use strict;
|
|||
use warnings;
|
||||
use Carp;
|
||||
|
||||
|
||||
sub new {
|
||||
my ($class, $option_name, $option_value)= @_;
|
||||
my $self= bless { name => $option_name,
|
||||
|
@ -61,7 +60,7 @@ sub insert {
|
|||
$option->{value}= $value;
|
||||
}
|
||||
else {
|
||||
my $option= My::Config::Option->new($option_name, $value);
|
||||
$option= My::Config::Option->new($option_name, $value);
|
||||
# Insert option in list
|
||||
push(@{$self->{options}}, $option);
|
||||
# Insert option in hash
|
||||
|
@ -163,6 +162,62 @@ sub if_exist {
|
|||
return $option->value();
|
||||
}
|
||||
|
||||
package My::Config::Group::ENV;
|
||||
our @ISA=qw(My::Config::Group);
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use Carp;
|
||||
|
||||
sub new {
|
||||
my ($class, $group_name)= @_;
|
||||
bless My::Config::Group->new($group_name), $class;
|
||||
}
|
||||
|
||||
#
|
||||
# Return value for an option in the group, fail if it does not exist
|
||||
#
|
||||
sub value {
|
||||
my ($self, $option_name)= @_;
|
||||
my $option= $self->option($option_name);
|
||||
|
||||
if (! defined($option) and defined $ENV{$option_name}) {
|
||||
my $value= $ENV{$option_name};
|
||||
$option= My::Config::Option->new($option_name, $value);
|
||||
}
|
||||
|
||||
croak "No option named '$option_name' in group '$self->{name}'"
|
||||
if ! defined($option);
|
||||
|
||||
return $option->value();
|
||||
}
|
||||
|
||||
package My::Config::Group::OPT;
|
||||
our @ISA=qw(My::Config::Group);
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
use Carp;
|
||||
|
||||
sub new {
|
||||
my ($class, $group_name)= @_;
|
||||
bless My::Config::Group->new($group_name), $class;
|
||||
}
|
||||
|
||||
sub options {
|
||||
my ($self)= @_;
|
||||
()
|
||||
}
|
||||
|
||||
sub value {
|
||||
my ($self, $option_name)= @_;
|
||||
my $option= $self->option($option_name);
|
||||
|
||||
croak "No option named '$option_name' in group '$self->{name}'"
|
||||
if ! defined($option);
|
||||
|
||||
return $option->value()->();
|
||||
}
|
||||
|
||||
package My::Config;
|
||||
|
||||
|
@ -182,7 +237,10 @@ sub new {
|
|||
my ($class, $path)= @_;
|
||||
my $group_name= undef;
|
||||
|
||||
my $self= bless { groups => [] }, $class;
|
||||
my $self= bless { groups => [
|
||||
My::Config::Group::ENV->new('ENV'),
|
||||
My::Config::Group::OPT->new('OPT'),
|
||||
] }, $class;
|
||||
my $F= IO::File->new($path, "<")
|
||||
or croak "Could not open '$path': $!";
|
||||
|
||||
|
@ -199,19 +257,13 @@ sub new {
|
|||
}
|
||||
|
||||
# Magic #! comments
|
||||
elsif ( $line =~ /^#\!/) {
|
||||
my $magic= $line;
|
||||
elsif ( $line =~ /^(#\!\S+)(?:\s*(.*?)\s*)?$/) {
|
||||
my ($magic, $arg)= ($1, $2);
|
||||
croak "Found magic comment '$magic' outside of group"
|
||||
unless $group_name;
|
||||
|
||||
#print "$magic\n";
|
||||
$self->insert($group_name, $magic, undef);
|
||||
}
|
||||
|
||||
# Comments
|
||||
elsif ( $line =~ /^#/ || $line =~ /^;/) {
|
||||
# Skip comment
|
||||
next;
|
||||
$self->insert($group_name, $magic, $arg);
|
||||
}
|
||||
|
||||
# Empty lines
|
||||
|
@ -236,7 +288,7 @@ sub new {
|
|||
}
|
||||
|
||||
# <option>
|
||||
elsif ( $line =~ /^([\@\w-]+)\s*$/ ) {
|
||||
elsif ( $line =~ /^(#?[\w-]+)\s*$/ ) {
|
||||
my $option= $1;
|
||||
|
||||
croak "Found option '$option' outside of group"
|
||||
|
@ -247,7 +299,7 @@ sub new {
|
|||
}
|
||||
|
||||
# <option>=<value>
|
||||
elsif ( $line =~ /^([\@\w-]+)\s*=\s*(.*?)\s*$/ ) {
|
||||
elsif ( $line =~ /^(#?[\w-]+)\s*=\s*(.*?)\s*$/ ) {
|
||||
my $option= $1;
|
||||
my $value= $2;
|
||||
|
||||
|
@ -256,10 +308,17 @@ sub new {
|
|||
|
||||
#print "$option=$value\n";
|
||||
$self->insert($group_name, $option, $value);
|
||||
} else {
|
||||
croak "Unexpected line '$line' found in '$path'";
|
||||
}
|
||||
|
||||
# Comments
|
||||
elsif ( $line =~ /^#/ || $line =~ /^;/) {
|
||||
# Skip comment
|
||||
next;
|
||||
}
|
||||
|
||||
else {
|
||||
croak "Unexpected line '$line' found in '$path'";
|
||||
}
|
||||
}
|
||||
undef $F; # Close the file
|
||||
|
||||
|
@ -437,44 +496,4 @@ sub exists {
|
|||
return defined($option);
|
||||
}
|
||||
|
||||
|
||||
# Overload "to string"-operator with 'stringify'
|
||||
use overload
|
||||
'""' => \&stringify;
|
||||
|
||||
#
|
||||
# Return the config as a string in my.cnf file format
|
||||
#
|
||||
sub stringify {
|
||||
my ($self)= @_;
|
||||
my $res;
|
||||
|
||||
foreach my $group ($self->groups()) {
|
||||
$res .= "[$group->{name}]\n";
|
||||
|
||||
foreach my $option ($group->options()) {
|
||||
$res .= $option->name();
|
||||
my $value= $option->value();
|
||||
if (defined $value) {
|
||||
$res .= "=$value";
|
||||
}
|
||||
$res .= "\n";
|
||||
}
|
||||
$res .= "\n";
|
||||
}
|
||||
return $res;
|
||||
}
|
||||
|
||||
|
||||
#
|
||||
# Save the config to named file
|
||||
#
|
||||
sub save {
|
||||
my ($self, $path)= @_;
|
||||
my $F= IO::File->new($path, ">")
|
||||
or croak "Could not open '$path': $!";
|
||||
print $F $self;
|
||||
undef $F; # Close the file
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
|
@ -57,16 +57,12 @@ sub fix_pidfile {
|
|||
|
||||
sub fix_port {
|
||||
my ($self, $config, $group_name, $group)= @_;
|
||||
my $hostname= $group->value('#host');
|
||||
return $self->{HOSTS}->{$hostname}++;
|
||||
return $self->{PORT}++;
|
||||
}
|
||||
|
||||
sub fix_host {
|
||||
my ($self)= @_;
|
||||
# Get next host from HOSTS array
|
||||
my @hosts= keys(%{$self->{HOSTS}});;
|
||||
my $host_no= $self->{NEXT_HOST}++ % @hosts;
|
||||
return $hosts[$host_no];
|
||||
'localhost'
|
||||
}
|
||||
|
||||
sub is_unique {
|
||||
|
@ -229,7 +225,7 @@ if (IS_WINDOWS)
|
|||
sub fix_ndb_mgmd_port {
|
||||
my ($self, $config, $group_name, $group)= @_;
|
||||
my $hostname= $group->value('HostName');
|
||||
return $self->{HOSTS}->{$hostname}++;
|
||||
return $self->{PORT}++;
|
||||
}
|
||||
|
||||
|
||||
|
@ -428,20 +424,24 @@ sub post_check_embedded_group {
|
|||
|
||||
sub resolve_at_variable {
|
||||
my ($self, $config, $group, $option)= @_;
|
||||
local $_ = $option->value();
|
||||
my ($res, $after);
|
||||
|
||||
# Split the options value on last .
|
||||
my @parts= split(/\./, $option->value());
|
||||
my $option_name= pop(@parts);
|
||||
my $group_name= join('.', @parts);
|
||||
while (m/(.*?)\@((?:\w+\.)+)(#?[-\w]+)/g) {
|
||||
my ($before, $group_name, $option_name)= ($1, $2, $3);
|
||||
$after = $';
|
||||
chop($group_name);
|
||||
|
||||
$group_name =~ s/^\@//; # Remove at
|
||||
my $from_group= $config->group($group_name)
|
||||
or croak "There is no group named '$group_name' that ",
|
||||
"can be used to resolve '$option_name'";
|
||||
|
||||
my $from_group= $config->group($group_name)
|
||||
or croak "There is no group named '$group_name' that ",
|
||||
"can be used to resolve '$option_name'";
|
||||
my $value= $from_group->value($option_name);
|
||||
$res .= $before.$value;
|
||||
}
|
||||
$res .= $after;
|
||||
|
||||
my $from= $from_group->value($option_name);
|
||||
$config->insert($group->name(), $option->name(), $from)
|
||||
$config->insert($group->name(), $option->name(), $res)
|
||||
}
|
||||
|
||||
|
||||
|
@ -453,7 +453,7 @@ sub post_fix_resolve_at_variables {
|
|||
next unless defined $option->value();
|
||||
|
||||
$self->resolve_at_variable($config, $group, $option)
|
||||
if ($option->value() =~ /^\@/);
|
||||
if ($option->value() =~ /\@/);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -595,28 +595,18 @@ sub new_config {
|
|||
croak "you must pass '$required'" unless defined $args->{$required};
|
||||
}
|
||||
|
||||
# Fill in hosts/port hash
|
||||
my $hosts= {};
|
||||
my $baseport= $args->{baseport};
|
||||
$args->{hosts}= [ 'localhost' ] unless exists($args->{hosts});
|
||||
foreach my $host ( @{$args->{hosts}} ) {
|
||||
$hosts->{$host}= $baseport;
|
||||
}
|
||||
|
||||
# Open the config template
|
||||
my $config= My::Config->new($args->{'template_path'});
|
||||
my $extra_template_path= $args->{'extra_template_path'};
|
||||
if ($extra_template_path){
|
||||
$config->append(My::Config->new($extra_template_path));
|
||||
}
|
||||
my $self= bless {
|
||||
CONFIG => $config,
|
||||
ARGS => $args,
|
||||
HOSTS => $hosts,
|
||||
NEXT_HOST => 0,
|
||||
PORT => $args->{baseport},
|
||||
SERVER_ID => 1,
|
||||
}, $class;
|
||||
|
||||
# add auto-options
|
||||
$config->insert('OPT', 'port' => sub { fix_port($self, $config) });
|
||||
$config->insert('OPT', 'vardir' => sub { shift->{ARGS}->{vardir} });
|
||||
|
||||
{
|
||||
# Run pre rules
|
||||
|
|
0
mysql-test/lib/My/Handles.pm
Executable file → Normal file
0
mysql-test/lib/My/Handles.pm
Executable file → Normal file
|
@ -120,7 +120,7 @@ sub new {
|
|||
my $input = delete($opts{'input'});
|
||||
my $output = delete($opts{'output'});
|
||||
my $error = delete($opts{'error'});
|
||||
my $verbose = delete($opts{'verbose'});
|
||||
my $verbose = delete($opts{'verbose'}) || $::opt_verbose;
|
||||
my $nocore = delete($opts{'nocore'});
|
||||
my $host = delete($opts{'host'});
|
||||
my $shutdown = delete($opts{'shutdown'});
|
||||
|
|
|
@ -160,7 +160,7 @@ int main(int argc, char* const argv[] )
|
|||
signal(SIGCHLD, handle_signal);
|
||||
signal(SIGABRT, handle_abort);
|
||||
|
||||
sprintf(safe_process_name, "safe_process[%d]", (int) own_pid);
|
||||
sprintf(safe_process_name, "safe_process[%ld]", (long) own_pid);
|
||||
|
||||
message("Started");
|
||||
|
||||
|
|
10
mysql-test/lib/My/Suite.pm
Normal file
10
mysql-test/lib/My/Suite.pm
Normal file
|
@ -0,0 +1,10 @@
|
|||
# A default suite class that is used for all suites without their owns suite.pm
|
||||
# see README.suites for a description
|
||||
|
||||
package My::Suite;
|
||||
|
||||
sub config_files { () }
|
||||
sub servers { () }
|
||||
|
||||
bless { };
|
||||
|
|
@ -20,6 +20,12 @@ sub new {
|
|||
return $self;
|
||||
}
|
||||
|
||||
sub fullname {
|
||||
my ($self)= @_;
|
||||
$self->{name} . (defined $self->{combination}
|
||||
? " '$self->{combination}'"
|
||||
: "")
|
||||
}
|
||||
|
||||
#
|
||||
# Return a unique key that can be used to
|
||||
|
|
|
@ -39,7 +39,6 @@ our $enable_disabled;
|
|||
our $default_storage_engine;
|
||||
our $opt_with_ndbcluster_only;
|
||||
our $defaults_file;
|
||||
our $defaults_extra_file;
|
||||
our $quick_collect;
|
||||
|
||||
sub collect_option {
|
||||
|
@ -68,21 +67,10 @@ require "mtr_misc.pl";
|
|||
my $do_test_reg;
|
||||
my $skip_test_reg;
|
||||
|
||||
# Related to adding InnoDB plugin combinations
|
||||
my $lib_innodb_plugin;
|
||||
|
||||
# If "Quick collect", set to 1 once a test to run has been found.
|
||||
my $some_test_found;
|
||||
|
||||
sub find_innodb_plugin {
|
||||
$lib_innodb_plugin=
|
||||
my_find_file($::basedir,
|
||||
["storage/innodb_plugin", "storage/innodb_plugin/.libs",
|
||||
"lib/mysql/plugin", "lib/plugin"],
|
||||
["ha_innodb_plugin.dll", "ha_innodb_plugin.so",
|
||||
"ha_innodb_plugin.sl"],
|
||||
NOT_REQUIRED);
|
||||
}
|
||||
my $default_suite_object = do 'My/Suite.pm';
|
||||
|
||||
sub init_pattern {
|
||||
my ($from, $what)= @_;
|
||||
|
@ -116,8 +104,6 @@ sub collect_test_cases ($$$) {
|
|||
$do_test_reg= init_pattern($do_test, "--do-test");
|
||||
$skip_test_reg= init_pattern($skip_test, "--skip-test");
|
||||
|
||||
&find_innodb_plugin;
|
||||
|
||||
# If not reordering, we also shouldn't group by suites, unless
|
||||
# no test cases were named.
|
||||
# This also effects some logic in the loop following this.
|
||||
|
@ -188,17 +174,17 @@ sub collect_test_cases ($$$) {
|
|||
my $opts= $tinfo->{'master_opt'} ? $tinfo->{'master_opt'} : [];
|
||||
push(@criteria, join("!", sort @{$opts}) . "~");
|
||||
|
||||
$sort_criteria{$tinfo->{name}} = join(" ", @criteria);
|
||||
$sort_criteria{$tinfo->fullname()} = join(" ", @criteria);
|
||||
}
|
||||
|
||||
@$cases = sort {
|
||||
$sort_criteria{$a->{'name'}} . $a->{'name'} cmp
|
||||
$sort_criteria{$b->{'name'}} . $b->{'name'}; } @$cases;
|
||||
$sort_criteria{$a->fullname()} . $a->fullname() cmp
|
||||
$sort_criteria{$b->fullname()} . $b->fullname() } @$cases;
|
||||
|
||||
# For debugging the sort-order
|
||||
# foreach my $tinfo (@$cases)
|
||||
# {
|
||||
# print("$sort_criteria{$tinfo->{'name'}} -> \t$tinfo->{'name'}\n");
|
||||
# print $sort_criteria{$tinfo->fullname()}," -> \t",$tinfo->fullname(),"\n";
|
||||
# }
|
||||
|
||||
}
|
||||
|
@ -310,6 +296,17 @@ sub collect_one_suite
|
|||
mtr_verbose("testdir: $testdir");
|
||||
mtr_verbose("resdir: $resdir");
|
||||
|
||||
#
|
||||
# Load the Suite object
|
||||
#
|
||||
unless ($::suites{$suite}) {
|
||||
if (-f "$suitedir/suite.pm") {
|
||||
$::suites{$suite} = do "$suitedir/suite.pm";
|
||||
} else {
|
||||
$::suites{$suite} = $default_suite_object;
|
||||
}
|
||||
}
|
||||
|
||||
# ----------------------------------------------------------------------
|
||||
# Build a hash of disabled testcases for this suite
|
||||
# ----------------------------------------------------------------------
|
||||
|
@ -328,12 +325,8 @@ sub collect_one_suite
|
|||
}
|
||||
|
||||
# Read suite.opt file
|
||||
my $suite_opt_file= "$testdir/suite.opt";
|
||||
my $suite_opts= [];
|
||||
if ( -f $suite_opt_file )
|
||||
{
|
||||
$suite_opts= opts_from_file($suite_opt_file);
|
||||
}
|
||||
my $suite_opts= [ opts_from_file("$testdir/suite.opt") ];
|
||||
$suite_opts = [ opts_from_file("$suitedir/suite.opt") ] unless @$suite_opts;
|
||||
|
||||
if ( @$opt_cases )
|
||||
{
|
||||
|
@ -438,14 +431,16 @@ sub collect_one_suite
|
|||
{
|
||||
# Read combinations file in my.cnf format
|
||||
mtr_verbose("Read combinations file");
|
||||
my %env_filter = map { $_ => 1 } split /:/, $ENV{"\U${suite}_COMBINATIONS"};
|
||||
my $config= My::Config->new($combination_file);
|
||||
foreach my $group ($config->groups()) {
|
||||
my $comb= {};
|
||||
$comb->{name}= $group->name();
|
||||
next if %env_filter and not $env_filter{$comb->{name}};
|
||||
foreach my $option ( $group->options() ) {
|
||||
push(@{$comb->{comb_opt}}, $option->option());
|
||||
}
|
||||
push(@combinations, $comb);
|
||||
push(@combinations, $comb) if $comb->{comb_opt};
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -539,28 +534,7 @@ sub optimize_cases {
|
|||
# support it
|
||||
# =======================================================
|
||||
#print "binlog_format: $binlog_format\n";
|
||||
if (defined $binlog_format )
|
||||
{
|
||||
# =======================================================
|
||||
# Fixed --binlog-format=x specified on command line
|
||||
# =======================================================
|
||||
if ( defined $tinfo->{'binlog_formats'} )
|
||||
{
|
||||
#print "binlog_formats: ". join(", ", @{$tinfo->{binlog_formats}})."\n";
|
||||
|
||||
# The test supports different binlog formats
|
||||
# check if the selected one is ok
|
||||
my $supported=
|
||||
grep { $_ eq $binlog_format } @{$tinfo->{'binlog_formats'}};
|
||||
if ( !$supported )
|
||||
{
|
||||
$tinfo->{'skip'}= 1;
|
||||
$tinfo->{'comment'}=
|
||||
"Doesn't support --binlog-format='$binlog_format'";
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
if (not defined $binlog_format )
|
||||
{
|
||||
# =======================================================
|
||||
# Use dynamic switching of binlog format
|
||||
|
@ -623,10 +597,6 @@ sub optimize_cases {
|
|||
|
||||
$tinfo->{'ndb_test'}= 1
|
||||
if ( $default_engine =~ /^ndb/i );
|
||||
$tinfo->{'innodb_test'}= 1
|
||||
if ( $default_engine =~ /^innodb/i );
|
||||
$tinfo->{'pbxt_test'}= 1
|
||||
if ( $default_engine =~ /^pbxt/i );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -644,67 +614,78 @@ sub optimize_cases {
|
|||
# Read options from the given opt file and append them as an array
|
||||
# to $tinfo->{$opt_name}
|
||||
#
|
||||
sub process_opts_file {
|
||||
my ($tinfo, $opt_file, $opt_name)= @_;
|
||||
sub process_opts {
|
||||
my ($tinfo, $opt_name)= @_;
|
||||
|
||||
if ( -f $opt_file )
|
||||
my @opts= @{$tinfo->{$opt_name}};
|
||||
$tinfo->{$opt_name} = [];
|
||||
|
||||
my @plugins;
|
||||
|
||||
foreach my $opt (@opts)
|
||||
{
|
||||
my $opts= opts_from_file($opt_file);
|
||||
my $value;
|
||||
|
||||
foreach my $opt ( @$opts )
|
||||
# The opt file is used both to send special options to the mysqld
|
||||
# as well as pass special test case specific options to this
|
||||
# script
|
||||
|
||||
$value= mtr_match_prefix($opt, "--timezone=");
|
||||
if ( defined $value )
|
||||
{
|
||||
my $value;
|
||||
|
||||
# The opt file is used both to send special options to the mysqld
|
||||
# as well as pass special test case specific options to this
|
||||
# script
|
||||
|
||||
$value= mtr_match_prefix($opt, "--timezone=");
|
||||
if ( defined $value )
|
||||
{
|
||||
$tinfo->{'timezone'}= $value;
|
||||
next;
|
||||
}
|
||||
|
||||
$value= mtr_match_prefix($opt, "--result-file=");
|
||||
if ( defined $value )
|
||||
{
|
||||
# Specifies the file mysqltest should compare
|
||||
# output against
|
||||
$tinfo->{'result_file'}= "r/$value.result";
|
||||
next;
|
||||
}
|
||||
|
||||
$value= mtr_match_prefix($opt, "--config-file-template=");
|
||||
if ( defined $value)
|
||||
{
|
||||
# Specifies the configuration file to use for this test
|
||||
$tinfo->{'template_path'}= dirname($tinfo->{path})."/$value";
|
||||
next;
|
||||
}
|
||||
|
||||
# If we set default time zone, remove the one we have
|
||||
$value= mtr_match_prefix($opt, "--default-time-zone=");
|
||||
if ( defined $value )
|
||||
{
|
||||
# Set timezone for this test case to something different
|
||||
$tinfo->{'timezone'}= "GMT-8";
|
||||
# Fallthrough, add the --default-time-zone option
|
||||
}
|
||||
|
||||
# The --restart option forces a restart even if no special
|
||||
# option is set. If the options are the same as next testcase
|
||||
# there is no need to restart after the testcase
|
||||
# has completed
|
||||
if ( $opt eq "--force-restart" )
|
||||
{
|
||||
$tinfo->{'force_restart'}= 1;
|
||||
next;
|
||||
}
|
||||
|
||||
# Ok, this was a real option, add it
|
||||
push(@{$tinfo->{$opt_name}}, $opt);
|
||||
$tinfo->{'timezone'}= $value;
|
||||
next;
|
||||
}
|
||||
|
||||
$value= mtr_match_prefix($opt, "--plugin-load=");
|
||||
if (defined $value)
|
||||
{
|
||||
push @plugins, $value;
|
||||
next;
|
||||
}
|
||||
|
||||
$value= mtr_match_prefix($opt, "--result-file=");
|
||||
if ( defined $value )
|
||||
{
|
||||
# Specifies the file mysqltest should compare
|
||||
# output against
|
||||
$tinfo->{'result_file'}= "r/$value.result";
|
||||
next;
|
||||
}
|
||||
|
||||
$value= mtr_match_prefix($opt, "--config-file-template=");
|
||||
if ( defined $value)
|
||||
{
|
||||
# Specifies the configuration file to use for this test
|
||||
$tinfo->{'template_path'}= dirname($tinfo->{path})."/$value";
|
||||
next;
|
||||
}
|
||||
|
||||
# If we set default time zone, remove the one we have
|
||||
$value= mtr_match_prefix($opt, "--default-time-zone=");
|
||||
if ( defined $value )
|
||||
{
|
||||
# Set timezone for this test case to something different
|
||||
$tinfo->{'timezone'}= "GMT-8";
|
||||
# Fallthrough, add the --default-time-zone option
|
||||
}
|
||||
|
||||
# The --restart option forces a restart even if no special
|
||||
# option is set. If the options are the same as next testcase
|
||||
# there is no need to restart after the testcase
|
||||
# has completed
|
||||
if ( $opt eq "--force-restart" )
|
||||
{
|
||||
$tinfo->{'force_restart'}= 1;
|
||||
next;
|
||||
}
|
||||
|
||||
# Ok, this was a real option, add it
|
||||
push(@{$tinfo->{$opt_name}}, $opt);
|
||||
}
|
||||
|
||||
if (@plugins) {
|
||||
push @{$tinfo->{$opt_name}}, "--plugin-load=" . join(':', @plugins);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -758,7 +739,7 @@ sub collect_one_test_case {
|
|||
name => "$suitename.$tname",
|
||||
shortname => $tname,
|
||||
path => "$testdir/$filename",
|
||||
|
||||
suite => $suitename,
|
||||
);
|
||||
|
||||
my $result_file= "$resdir/$tname.result";
|
||||
|
@ -880,7 +861,7 @@ sub collect_one_test_case {
|
|||
if ( -f "$testdir/$tname.slave-mi");
|
||||
|
||||
|
||||
tags_from_test_file($tinfo,"$testdir/${tname}.test");
|
||||
my @source_files = tags_from_test_file($tinfo,"$testdir/${tname}.test");
|
||||
|
||||
# Get default storage engine from suite.opt file
|
||||
|
||||
|
@ -897,12 +878,6 @@ sub collect_one_test_case {
|
|||
$tinfo->{'ndb_test'}= 1
|
||||
if ( $local_default_storage_engine =~ /^ndb/i );
|
||||
|
||||
$tinfo->{'innodb_test'}= 1
|
||||
if ( $local_default_storage_engine =~ /^innodb/i );
|
||||
|
||||
$tinfo->{'pbxt_test'}= 1
|
||||
if ( $local_default_storage_engine =~ /^pbxt/i );
|
||||
|
||||
}
|
||||
|
||||
if ( $tinfo->{'big_test'} and ! $::opt_big_test )
|
||||
|
@ -949,72 +924,6 @@ sub collect_one_test_case {
|
|||
}
|
||||
}
|
||||
|
||||
if ($tinfo->{'federated_test'})
|
||||
{
|
||||
# This is a test that needs federated, enable it
|
||||
push(@{$tinfo->{'master_opt'}}, "--loose-federated");
|
||||
push(@{$tinfo->{'slave_opt'}}, "--loose-federated");
|
||||
}
|
||||
|
||||
if ( $tinfo->{'innodb_test'} )
|
||||
{
|
||||
# This is a test that needs innodb
|
||||
if ( $::mysqld_variables{'innodb'} eq "OFF" ||
|
||||
! exists $::mysqld_variables{'innodb'} )
|
||||
{
|
||||
# innodb is not supported, skip it
|
||||
$tinfo->{'skip'}= 1;
|
||||
$tinfo->{'comment'}= "No innodb support";
|
||||
return $tinfo;
|
||||
}
|
||||
}
|
||||
elsif ( $tinfo->{'innodb_plugin_test'} )
|
||||
{
|
||||
# This is a test that needs the innodb plugin
|
||||
if (&find_innodb_plugin)
|
||||
{
|
||||
my $sep= (IS_WINDOWS) ? ';' : ':';
|
||||
my $plugin_filename= basename($lib_innodb_plugin);
|
||||
my $plugin_list=
|
||||
"innodb=$plugin_filename$sep" .
|
||||
"innodb_trx=$plugin_filename$sep" .
|
||||
"innodb_locks=$plugin_filename$sep" .
|
||||
"innodb_lock_waits=$plugin_filename$sep" .
|
||||
"innodb_cmp=$plugin_filename$sep" .
|
||||
"innodb_cmp_reset=$plugin_filename$sep" .
|
||||
"innodb_cmpmem=$plugin_filename$sep" .
|
||||
"innodb_cmpmem_reset=$plugin_filename";
|
||||
|
||||
foreach my $k ('master_opt', 'slave_opt') {
|
||||
push(@{$tinfo->{$k}}, '--ignore-builtin-innodb');
|
||||
push(@{$tinfo->{$k}}, '--plugin-dir=' . dirname($lib_innodb_plugin));
|
||||
push(@{$tinfo->{$k}}, "--plugin-load=$plugin_list");
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
push(@{$tinfo->{'master_opt'}}, "--loose-skip-innodb");
|
||||
push(@{$tinfo->{'slave_opt'}}, "--loose-skip-innodb");
|
||||
}
|
||||
|
||||
if ( $tinfo->{'need_binlog'} )
|
||||
{
|
||||
if (grep(/^--skip-log-bin/, @::opt_extra_mysqld_opt) )
|
||||
{
|
||||
$tinfo->{'skip'}= 1;
|
||||
$tinfo->{'comment'}= "Test needs binlog";
|
||||
return $tinfo;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
# Test does not need binlog, add --skip-binlog to
|
||||
# the options used when starting
|
||||
push(@{$tinfo->{'master_opt'}}, "--loose-skip-log-bin");
|
||||
push(@{$tinfo->{'slave_opt'}}, "--loose-skip-log-bin");
|
||||
}
|
||||
|
||||
if ( $tinfo->{'rpl_test'} )
|
||||
{
|
||||
if ( $skip_rpl )
|
||||
|
@ -1085,28 +994,6 @@ sub collect_one_test_case {
|
|||
$tinfo->{template_path}= $config;
|
||||
}
|
||||
|
||||
if ( $tinfo->{'pbxt_test'} )
|
||||
{
|
||||
# This is a test that needs pbxt
|
||||
if ( $::mysqld_variables{'pbxt'} eq "OFF" ||
|
||||
! exists $::mysqld_variables{'pbxt'} )
|
||||
{
|
||||
# Engine is not supported, skip it
|
||||
$tinfo->{'skip'}= 1;
|
||||
return $tinfo;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
# Only disable engine if it's on by default (to avoid warnings about
|
||||
# not existing loose options
|
||||
if ( $::mysqld_variables{'pbxt'} eq "ON")
|
||||
{
|
||||
push(@{$tinfo->{'master_opt'}}, "--loose-skip-pbxt");
|
||||
push(@{$tinfo->{'slave_opt'}}, "--loose-skip-pbxt");
|
||||
}
|
||||
}
|
||||
|
||||
if ( $tinfo->{'example_plugin_test'} )
|
||||
{
|
||||
if ( !$ENV{'HA_EXAMPLE_SO'} )
|
||||
|
@ -1117,27 +1004,29 @@ sub collect_one_test_case {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
# Set extra config file to use
|
||||
if (defined $defaults_extra_file) {
|
||||
$tinfo->{extra_template_path}= $defaults_extra_file;
|
||||
if (not ref $::suites{$tinfo->{suite}})
|
||||
{
|
||||
$tinfo->{'skip'}= 1;
|
||||
$tinfo->{'comment'}= $::suites{$tinfo->{suite}};
|
||||
return $tinfo;
|
||||
}
|
||||
|
||||
# ----------------------------------------------------------------------
|
||||
# Append mysqld extra options to both master and slave
|
||||
# Append mysqld extra options to master and slave, as appropriate
|
||||
# ----------------------------------------------------------------------
|
||||
for (@source_files) {
|
||||
s/\.\w+$//;
|
||||
push @{$tinfo->{master_opt}}, opts_from_file("$_.opt");
|
||||
push @{$tinfo->{slave_opt}}, opts_from_file("$_.opt");
|
||||
push @{$tinfo->{master_opt}}, opts_from_file("$_-master.opt");
|
||||
push @{$tinfo->{slave_opt}}, opts_from_file("$_-slave.opt");
|
||||
}
|
||||
|
||||
push(@{$tinfo->{'master_opt'}}, @::opt_extra_mysqld_opt);
|
||||
push(@{$tinfo->{'slave_opt'}}, @::opt_extra_mysqld_opt);
|
||||
|
||||
# ----------------------------------------------------------------------
|
||||
# Add master opts, extra options only for master
|
||||
# ----------------------------------------------------------------------
|
||||
process_opts_file($tinfo, "$testdir/$tname-master.opt", 'master_opt');
|
||||
|
||||
# ----------------------------------------------------------------------
|
||||
# Add slave opts, list of extra option only for slave
|
||||
# ----------------------------------------------------------------------
|
||||
process_opts_file($tinfo, "$testdir/$tname-slave.opt", 'slave_opt');
|
||||
process_opts($tinfo, 'master_opt');
|
||||
process_opts($tinfo, 'slave_opt');
|
||||
|
||||
return $tinfo;
|
||||
}
|
||||
|
@ -1147,24 +1036,6 @@ sub collect_one_test_case {
|
|||
# the specified value in "tinfo"
|
||||
my @tags=
|
||||
(
|
||||
["include/have_binlog_format_row.inc", "binlog_formats", ["row"]],
|
||||
["include/have_binlog_format_statement.inc", "binlog_formats", ["statement"]],
|
||||
["include/have_binlog_format_mixed.inc", "binlog_formats", ["mixed"]],
|
||||
["include/have_binlog_format_mixed_or_row.inc",
|
||||
"binlog_formats", ["mixed", "row"]],
|
||||
["include/have_binlog_format_mixed_or_statement.inc",
|
||||
"binlog_formats", ["mixed", "statement"]],
|
||||
["include/have_binlog_format_row_or_statement.inc",
|
||||
"binlog_formats", ["row", "statement"]],
|
||||
|
||||
["include/have_log_bin.inc", "need_binlog", 1],
|
||||
|
||||
["include/have_innodb.inc", "innodb_test", 1],
|
||||
["include/have_innodb_plugin.inc", "innodb_plugin_test", 1],
|
||||
["include/have_real.inc", "innodb_test", 1],
|
||||
["include/have_real_innodb_plugin.inc", "innodb_plugin_test", 1],
|
||||
["include/have_xtradb.inc", "innodb_test", 1],
|
||||
["include/have_pbxt.inc", "pbxt_test", 1],
|
||||
["include/big_test.inc", "big_test", 1],
|
||||
["include/have_debug.inc", "need_debug", 1],
|
||||
["include/have_ndb.inc", "ndb_test", 1],
|
||||
|
@ -1172,7 +1043,6 @@ my @tags=
|
|||
["include/master-slave.inc", "rpl_test", 1],
|
||||
["include/ndb_master-slave.inc", "rpl_test", 1],
|
||||
["include/ndb_master-slave.inc", "ndb_test", 1],
|
||||
["federated.inc", "federated_test", 1],
|
||||
["include/not_embedded.inc", "not_embedded", 1],
|
||||
["include/not_valgrind.inc", "not_valgrind", 1],
|
||||
["include/have_example_plugin.inc", "example_plugin_test", 1],
|
||||
|
@ -1185,6 +1055,7 @@ sub tags_from_test_file {
|
|||
my $file= shift;
|
||||
#mtr_verbose("$file");
|
||||
my $F= IO::File->new($file) or mtr_error("can't open file \"$file\": $!");
|
||||
my @all_files=($file);
|
||||
|
||||
while ( my $line= <$F> )
|
||||
{
|
||||
|
@ -1220,13 +1091,13 @@ sub tags_from_test_file {
|
|||
# Only source the file if it exists, we may get
|
||||
# false positives in the regexes above if someone
|
||||
# writes "source nnnn;" in a test case(such as mysqltest.test)
|
||||
tags_from_test_file($tinfo, $sourced_file);
|
||||
unshift @all_files, tags_from_test_file($tinfo, $sourced_file);
|
||||
last;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@all_files;
|
||||
}
|
||||
|
||||
sub unspace {
|
||||
|
@ -1239,6 +1110,9 @@ sub unspace {
|
|||
|
||||
sub opts_from_file ($) {
|
||||
my $file= shift;
|
||||
local $_;
|
||||
|
||||
return () unless -f $file;
|
||||
|
||||
open(FILE,"<",$file) or mtr_error("can't open file \"$file\": $!");
|
||||
my @args;
|
||||
|
@ -1280,7 +1154,7 @@ sub opts_from_file ($) {
|
|||
}
|
||||
}
|
||||
close FILE;
|
||||
return \@args;
|
||||
return @args;
|
||||
}
|
||||
|
||||
sub print_testcases {
|
||||
|
|
|
@ -61,14 +61,10 @@ sub _name {
|
|||
|
||||
sub _mtr_report_test_name ($) {
|
||||
my $tinfo= shift;
|
||||
my $tname= $tinfo->{name};
|
||||
my $tname= $tinfo->fullname();
|
||||
|
||||
return unless defined $verbose;
|
||||
|
||||
# Add combination name if any
|
||||
$tname.= " '$tinfo->{combination}'"
|
||||
if defined $tinfo->{combination};
|
||||
|
||||
print _name(). _timestamp();
|
||||
printf "%-40s ", $tname;
|
||||
my $worker = $tinfo->{worker};
|
||||
|
|
|
@ -130,7 +130,7 @@ my $path_config_file; # The generated config file, var/my.cnf
|
|||
# executables will be used by the test suite.
|
||||
our $opt_vs_config = $ENV{'MTR_VS_CONFIG'};
|
||||
|
||||
my $DEFAULT_SUITES= "main,binlog,federated,rpl,maria,parts,innodb,innodb_plugin,percona";
|
||||
my $DEFAULT_SUITES= "main,binlog,federated,rpl,maria,parts,innodb,innodb_plugin,percona,ndb";
|
||||
my $opt_suites;
|
||||
|
||||
our $opt_verbose= 0; # Verbose output, enable with --verbose
|
||||
|
@ -257,6 +257,8 @@ our $debug_compiled_binaries;
|
|||
|
||||
our %mysqld_variables;
|
||||
|
||||
our %suites;
|
||||
|
||||
my $source_dist= 0;
|
||||
|
||||
my $opt_max_save_core= env_or_val(MTR_MAX_SAVE_CORE => 5);
|
||||
|
@ -711,6 +713,8 @@ sub run_test_server ($$$) {
|
|||
$next= splice(@$tests, $second_best, 1);
|
||||
}
|
||||
|
||||
xterm_stat(scalar(@$tests));
|
||||
|
||||
if ($next) {
|
||||
#$next->print_test();
|
||||
$next->write_test($sock, 'TESTCASE');
|
||||
|
@ -807,7 +811,7 @@ sub run_worker ($) {
|
|||
# We need to gracefully shut down the servers to see any
|
||||
# Valgrind memory leak errors etc. since last server restart.
|
||||
if ($opt_warnings) {
|
||||
stop_servers(all_servers());
|
||||
stop_servers(reverse all_servers());
|
||||
if(check_warnings_post_shutdown($server)) {
|
||||
# Warnings appeared in log file(s) during final server shutdown.
|
||||
exit(1);
|
||||
|
@ -1595,7 +1599,7 @@ sub collect_mysqld_features {
|
|||
my $cmd= join(" ", $exe_mysqld, @$args);
|
||||
my $list= `$cmd`;
|
||||
|
||||
print "cmd: $cmd\n";
|
||||
mtr_verbose("cmd: $cmd");
|
||||
|
||||
foreach my $line (split('\n', $list))
|
||||
{
|
||||
|
@ -1802,6 +1806,7 @@ sub mysql_fix_arguments () {
|
|||
mtr_add_arg($args, "--basedir=%s", $basedir);
|
||||
mtr_add_arg($args, "--bindir=%s", $path_client_bindir);
|
||||
mtr_add_arg($args, "--verbose");
|
||||
mtr_add_arg($args, "--sync-sys=0"); # Speed up test suite
|
||||
return mtr_args2str($exe, @$args);
|
||||
}
|
||||
|
||||
|
@ -2492,7 +2497,7 @@ sub check_ndbcluster_support ($) {
|
|||
}
|
||||
|
||||
|
||||
sub ndbcluster_wait_started($$){
|
||||
sub ndbcluster_wait_started {
|
||||
my $cluster= shift;
|
||||
my $ndb_waiter_extra_opt= shift;
|
||||
my $path_waitlog= join('/', $opt_vardir, $cluster->name(), "ndb_waiter.log");
|
||||
|
@ -2660,7 +2665,7 @@ sub ndbd_start {
|
|||
|
||||
|
||||
sub ndbcluster_start ($) {
|
||||
my $cluster= shift;
|
||||
my ($cluster) = @_;
|
||||
|
||||
mtr_verbose("ndbcluster_start '".$cluster->name()."'");
|
||||
|
||||
|
@ -2680,6 +2685,109 @@ sub ndbcluster_start ($) {
|
|||
}
|
||||
|
||||
|
||||
sub mysql_server_start($) {
|
||||
my ($mysqld, $tinfo) = @_;
|
||||
|
||||
if ( $mysqld->{proc} )
|
||||
{
|
||||
# Already started
|
||||
|
||||
# Write start of testcase to log file
|
||||
mark_log($mysqld->value('#log-error'), $tinfo);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
my $datadir= $mysqld->value('datadir');
|
||||
if (not $opt_start_dirty)
|
||||
{
|
||||
|
||||
my @options= ('log-bin', 'relay-log');
|
||||
foreach my $option_name ( @options ) {
|
||||
next unless $mysqld->option($option_name);
|
||||
|
||||
my $file_name= $mysqld->value($option_name);
|
||||
next unless
|
||||
defined $file_name and
|
||||
-e $file_name;
|
||||
|
||||
mtr_debug(" -removing '$file_name'");
|
||||
unlink($file_name) or die ("unable to remove file '$file_name'");
|
||||
}
|
||||
|
||||
if (-d $datadir ) {
|
||||
preserve_error_log($mysqld);
|
||||
mtr_verbose(" - removing '$datadir'");
|
||||
rmtree($datadir);
|
||||
}
|
||||
}
|
||||
|
||||
my $mysqld_basedir= $mysqld->value('basedir');
|
||||
if ( $basedir eq $mysqld_basedir )
|
||||
{
|
||||
if (! $opt_start_dirty) # If dirty, keep possibly grown system db
|
||||
{
|
||||
# Copy datadir from installed system db
|
||||
for my $path ( "$opt_vardir", "$opt_vardir/..") {
|
||||
my $install_db= "$path/install.db";
|
||||
copytree($install_db, $datadir)
|
||||
if -d $install_db;
|
||||
}
|
||||
mtr_error("Failed to copy system db to '$datadir'")
|
||||
unless -d $datadir;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
mysql_install_db($mysqld); # For versional testing
|
||||
|
||||
mtr_error("Failed to install system db to '$datadir'")
|
||||
unless -d $datadir;
|
||||
|
||||
}
|
||||
restore_error_log($mysqld);
|
||||
|
||||
# Create the servers tmpdir
|
||||
my $tmpdir= $mysqld->value('tmpdir');
|
||||
mkpath($tmpdir) unless -d $tmpdir;
|
||||
|
||||
# Write start of testcase to log file
|
||||
mark_log($mysqld->value('#log-error'), $tinfo);
|
||||
|
||||
# Run <tname>-master.sh
|
||||
if ($mysqld->option('#!run-master-sh') and
|
||||
run_sh_script($tinfo->{master_sh}) )
|
||||
{
|
||||
$tinfo->{'comment'}= "Failed to execute '$tinfo->{master_sh}'";
|
||||
return 1;
|
||||
}
|
||||
|
||||
# Run <tname>-slave.sh
|
||||
if ($mysqld->option('#!run-slave-sh') and
|
||||
run_sh_script($tinfo->{slave_sh}))
|
||||
{
|
||||
$tinfo->{'comment'}= "Failed to execute '$tinfo->{slave_sh}'";
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (!$opt_embedded_server)
|
||||
{
|
||||
my $extra_opts= get_extra_opts($mysqld, $tinfo);
|
||||
mysqld_start($mysqld,$extra_opts);
|
||||
|
||||
# Save this test case information, so next can examine it
|
||||
$mysqld->{'started_tinfo'}= $tinfo;
|
||||
}
|
||||
}
|
||||
|
||||
sub mysql_server_wait {
|
||||
my ($mysqld) = @_;
|
||||
|
||||
return not sleep_until_file_created($mysqld->value('pid-file'),
|
||||
$opt_start_timeout,
|
||||
$mysqld->{'proc'});
|
||||
}
|
||||
|
||||
sub create_config_file_for_extern {
|
||||
my %opts=
|
||||
(
|
||||
|
@ -3454,9 +3562,83 @@ sub restart_forced_by_test
|
|||
# Return timezone value of tinfo or default value
|
||||
sub timezone {
|
||||
my ($tinfo)= @_;
|
||||
return $tinfo->{timezone} || "DEFAULT";
|
||||
local $_ = $tinfo->{timezone};
|
||||
return 'DEFAULT' unless defined $_;
|
||||
no warnings 'uninitialized';
|
||||
s/\$\{(\w+)\}/$ENV{$1}/ge;
|
||||
s/\$(\w+)/$ENV{$1}/ge;
|
||||
$_;
|
||||
}
|
||||
|
||||
sub mycnf_create {
|
||||
my ($config) = @_;
|
||||
my $res;
|
||||
|
||||
foreach my $group ($config->groups()) {
|
||||
$res .= "[$group->{name}]\n";
|
||||
|
||||
foreach my $option ($group->options()) {
|
||||
$res .= $option->name();
|
||||
my $value= $option->value();
|
||||
if (defined $value) {
|
||||
$res .= "=$value";
|
||||
}
|
||||
$res .= "\n";
|
||||
}
|
||||
$res .= "\n";
|
||||
}
|
||||
$res;
|
||||
}
|
||||
|
||||
sub config_files($) {
|
||||
my ($tinfo) = @_;
|
||||
(
|
||||
'my.cnf' => \&mycnf_create,
|
||||
$suites{$tinfo->{suite}}->config_files()
|
||||
);
|
||||
}
|
||||
|
||||
sub _like { return $config ? $config->like($_[0]) : (); }
|
||||
sub mysqlds { return _like('mysqld\.'); }
|
||||
sub ndbds { return _like('cluster_config\.ndbd\.');}
|
||||
sub ndb_mgmds { return _like('cluster_config\.ndb_mgmd\.'); }
|
||||
|
||||
sub fix_servers($) {
|
||||
my ($tinfo) = @_;
|
||||
return () unless $config;
|
||||
my %servers = (
|
||||
qr/mysqld\./ => {
|
||||
SORT => 300,
|
||||
START => \&mysql_server_start,
|
||||
WAIT => \&mysql_server_wait,
|
||||
},
|
||||
qr/mysql_cluster\./ => {
|
||||
SORT => 200,
|
||||
START => \&ndbcluster_start,
|
||||
WAIT => \&ndbcluster_wait_started,
|
||||
},
|
||||
qr/cluster_config\.ndb_mgmd\./ => {
|
||||
SORT => 210,
|
||||
START => undef,
|
||||
},
|
||||
qr/cluster_config\.ndbd\./ => {
|
||||
SORT => 220,
|
||||
START => undef,
|
||||
},
|
||||
$suites{$tinfo->{suite}}->servers()
|
||||
);
|
||||
for ($config->groups()) {
|
||||
while (my ($re,$prop) = each %servers) {
|
||||
@$_{keys %$prop} = values %$prop if $_->{name} =~ /^$re/;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
sub all_servers {
|
||||
return unless $config;
|
||||
( sort { $a->{SORT} <=> $b->{SORT} }
|
||||
grep { defined $_->{SORT} } $config->groups() );
|
||||
}
|
||||
|
||||
# Storage for changed environment variables
|
||||
my %old_env;
|
||||
|
@ -3499,7 +3681,7 @@ sub run_testcase ($$) {
|
|||
if ( @restart != 0) {
|
||||
# Remember that we restarted for this test case (count restarts)
|
||||
$tinfo->{'restarted'}= 1;
|
||||
stop_servers(@restart );
|
||||
stop_servers(reverse @restart);
|
||||
if ($opt_warnings) {
|
||||
check_warnings_post_shutdown($server_socket);
|
||||
}
|
||||
|
@ -3535,7 +3717,6 @@ sub run_testcase ($$) {
|
|||
vardir => $opt_vardir,
|
||||
tmpdir => $opt_tmpdir,
|
||||
baseport => $baseport,
|
||||
#hosts => [ 'host1', 'host2' ],
|
||||
user => $opt_user,
|
||||
password => '',
|
||||
ssl => $opt_ssl_supported,
|
||||
|
@ -3543,8 +3724,16 @@ sub run_testcase ($$) {
|
|||
}
|
||||
);
|
||||
|
||||
# Write the new my.cnf
|
||||
$config->save($path_config_file);
|
||||
fix_servers($tinfo);
|
||||
|
||||
# Write config files:
|
||||
my %config_files = config_files($tinfo);
|
||||
while (my ($file, $generate) = each %config_files) {
|
||||
my ($path) = "$opt_vardir/$file";
|
||||
open (F, '>', $path) or die "Could not open '$path': $!";
|
||||
print F &$generate($config);
|
||||
close F;
|
||||
}
|
||||
|
||||
# Remember current config so a restart can occur when a test need
|
||||
# to use a different one
|
||||
|
@ -3687,7 +3876,7 @@ sub run_testcase ($$) {
|
|||
if ($opt_warnings) {
|
||||
# Checking error logs for warnings, so need to stop server
|
||||
# gracefully so that memory leaks etc. can be properly detected.
|
||||
stop_servers(all_servers());
|
||||
stop_servers(reverse all_servers());
|
||||
check_warnings_post_shutdown($server_socket);
|
||||
# Even if we got warnings here, we should not fail this
|
||||
# particular test, as the warnings may be caused by an earlier
|
||||
|
@ -3845,7 +4034,8 @@ sub run_testcase ($$) {
|
|||
# valuable debugging information even if there is no test failure recorded.
|
||||
sub _preserve_error_log_names {
|
||||
my ($mysqld)= @_;
|
||||
my $error_log_file= $mysqld->value('#log-error');
|
||||
my $error_log_file= $mysqld->if_exist('#log-error');
|
||||
return unless $error_log_file and -r $error_log_file;
|
||||
my $error_log_dir= dirname($error_log_file);
|
||||
my $save_name= $error_log_dir ."/../". $mysqld->name() .".error.log";
|
||||
return ($error_log_file, $save_name);
|
||||
|
@ -3854,14 +4044,14 @@ sub _preserve_error_log_names {
|
|||
sub preserve_error_log {
|
||||
my ($mysqld)= @_;
|
||||
my ($error_log_file, $save_name)= _preserve_error_log_names($mysqld);
|
||||
my $res= rename($error_log_file, $save_name);
|
||||
rename($error_log_file, $save_name) if $save_name;
|
||||
# Ignore any errors, as it's just a best-effort to keep the log if possible.
|
||||
}
|
||||
|
||||
sub restore_error_log {
|
||||
my ($mysqld)= @_;
|
||||
my ($error_log_file, $save_name)= _preserve_error_log_names($mysqld);
|
||||
my $res= rename($save_name, $error_log_file);
|
||||
rename($save_name, $error_log_file) if $save_name;
|
||||
}
|
||||
|
||||
# Keep track of last position in mysqld error log where we scanned for
|
||||
|
@ -3905,6 +4095,8 @@ sub pre_write_errorlog {
|
|||
|
||||
sub extract_server_log ($$) {
|
||||
my ($error_log, $tname) = @_;
|
||||
|
||||
return unless $error_log;
|
||||
|
||||
# Open the servers .err log file and read all lines
|
||||
# belonging to current test into @lines
|
||||
|
@ -3947,9 +4139,9 @@ sub get_log_from_proc ($$) {
|
|||
my ($proc, $name)= @_;
|
||||
my $srv_log= "";
|
||||
|
||||
foreach my $mysqld (mysqlds()) {
|
||||
foreach my $mysqld (all_servers()) {
|
||||
if ($mysqld->{proc} eq $proc) {
|
||||
my @srv_lines= extract_server_log($mysqld->value('#log-error'), $name);
|
||||
my @srv_lines= extract_server_log($mysqld->if_exist('#log-error'), $name);
|
||||
$srv_log= "\nServer log from this test:\n" . join ("", @srv_lines);
|
||||
last;
|
||||
}
|
||||
|
@ -4028,15 +4220,18 @@ sub extract_warning_lines ($) {
|
|||
my @antipatterns =
|
||||
(
|
||||
qr/error .*connecting to master/,
|
||||
qr/Plugin 'ndbcluster' will be forced to shutdown/,
|
||||
qr/InnoDB: Error: in ALTER TABLE `test`.`t[12]`/,
|
||||
qr/InnoDB: Error: table `test`.`t[12]` does not exist in the InnoDB internal/,
|
||||
qr/Slave: Unknown table 't1' Error_code: 1051/,
|
||||
qr/Slave SQL:.*(Error_code: [[:digit:]]+|Query:.*)/,
|
||||
qr/slave SQL thread aborted/,
|
||||
qr/unknown option '--loose-/,
|
||||
qr/unknown variable 'loose-/,
|
||||
qr/unknown option '--loose[-_]/,
|
||||
qr/unknown variable 'loose[-_]/,
|
||||
qr/Now setting lower_case_table_names to [02]/,
|
||||
qr/Setting lower_case_table_names=2/,
|
||||
qr/You have forced lower_case_table_names to 0/,
|
||||
qr/Plugin 'ndbcluster' will be forced to shutdow/,
|
||||
qr/deprecated/,
|
||||
qr/Slave SQL thread retried transaction/,
|
||||
qr/Slave \(additional info\)/,
|
||||
|
@ -4345,29 +4540,18 @@ sub clean_dir {
|
|||
|
||||
|
||||
sub clean_datadir {
|
||||
|
||||
mtr_verbose("Cleaning datadirs...");
|
||||
|
||||
if (started(all_servers()) != 0){
|
||||
mtr_error("Trying to clean datadir before all servers stopped");
|
||||
}
|
||||
|
||||
foreach my $cluster ( clusters() )
|
||||
for (all_servers())
|
||||
{
|
||||
my $cluster_dir= "$opt_vardir/".$cluster->{name};
|
||||
mtr_verbose(" - removing '$cluster_dir'");
|
||||
rmtree($cluster_dir);
|
||||
|
||||
}
|
||||
|
||||
foreach my $mysqld ( mysqlds() )
|
||||
{
|
||||
my $mysqld_dir= dirname($mysqld->value('datadir'));
|
||||
preserve_error_log($mysqld);
|
||||
if (-d $mysqld_dir ) {
|
||||
mtr_verbose(" - removing '$mysqld_dir'");
|
||||
rmtree($mysqld_dir);
|
||||
}
|
||||
preserve_error_log($_); # or at least, try to
|
||||
my $dir= "$opt_vardir/".$_->{name};
|
||||
mtr_verbose(" - removing '$dir'");
|
||||
rmtree($dir);
|
||||
}
|
||||
|
||||
# Remove all files in tmp and var/tmp
|
||||
|
@ -4390,17 +4574,6 @@ sub save_datadir_after_failure($$) {
|
|||
}
|
||||
|
||||
|
||||
sub remove_ndbfs_from_ndbd_datadir {
|
||||
my ($ndbd_datadir)= @_;
|
||||
# Remove the ndb_*_fs directory from ndbd.X/ dir
|
||||
foreach my $ndbfs_dir ( glob("$ndbd_datadir/ndb_*_fs") )
|
||||
{
|
||||
next unless -d $ndbfs_dir; # Skip if not a directory
|
||||
rmtree($ndbfs_dir);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
sub after_failure ($) {
|
||||
my ($tinfo)= @_;
|
||||
|
||||
|
@ -4417,31 +4590,18 @@ sub after_failure ($) {
|
|||
|
||||
mkpath($save_dir) if ! -d $save_dir;
|
||||
|
||||
# Save the used my.cnf file
|
||||
copy($path_config_file, $save_dir);
|
||||
# Save the used config files
|
||||
my %config_files = config_files($tinfo);
|
||||
while (my ($file, $generate) = each %config_files) {
|
||||
copy("$opt_vardir/$file", $save_dir);
|
||||
}
|
||||
|
||||
# Copy the tmp dir
|
||||
copytree("$opt_vardir/tmp/", "$save_dir/tmp/");
|
||||
|
||||
if ( clusters() ) {
|
||||
foreach my $cluster ( clusters() ) {
|
||||
my $cluster_dir= "$opt_vardir/".$cluster->{name};
|
||||
|
||||
# Remove the fileystem of each ndbd
|
||||
foreach my $ndbd ( in_cluster($cluster, ndbds()) )
|
||||
{
|
||||
my $ndbd_datadir= $ndbd->value("DataDir");
|
||||
remove_ndbfs_from_ndbd_datadir($ndbd_datadir);
|
||||
}
|
||||
|
||||
save_datadir_after_failure($cluster_dir, $save_dir);
|
||||
}
|
||||
}
|
||||
else {
|
||||
foreach my $mysqld ( mysqlds() ) {
|
||||
my $data_dir= $mysqld->value('datadir');
|
||||
save_datadir_after_failure(dirname($data_dir), $save_dir);
|
||||
}
|
||||
foreach (all_servers()) {
|
||||
my $dir= "$opt_vardir/".$_->{name};
|
||||
save_datadir_after_failure($dir, $save_dir);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -4540,7 +4700,7 @@ sub mysqld_stop {
|
|||
name => "mysqladmin shutdown ".$mysqld->name(),
|
||||
path => $exe_mysqladmin,
|
||||
args => \$args,
|
||||
error => "/dev/null",
|
||||
error => "$opt_vardir/log/mysqladmin.err",
|
||||
|
||||
);
|
||||
}
|
||||
|
@ -4579,8 +4739,8 @@ sub mysqld_arguments ($$$) {
|
|||
mtr_add_arg($args, "%s--log-output=table,file");
|
||||
}
|
||||
|
||||
# Check if "extra_opt" contains skip-log-bin
|
||||
my $skip_binlog= grep(/^(--|--loose-)skip-log-bin/, @$extra_opts);
|
||||
# Check if "extra_opt" contains --log-bin
|
||||
my $skip_binlog= not grep /^--(loose-)?log-bin/, @$extra_opts;
|
||||
|
||||
# Indicate to mysqld it will be debugged in debugger
|
||||
if ( $glob_debugger )
|
||||
|
@ -4836,8 +4996,7 @@ sub server_need_restart {
|
|||
return 1;
|
||||
}
|
||||
|
||||
my $is_mysqld= grep ($server eq $_, mysqlds());
|
||||
if ($is_mysqld)
|
||||
if ($server->name() =~ /^mysqld\./)
|
||||
{
|
||||
|
||||
# Check that running process was started with same options
|
||||
|
@ -4889,17 +5048,9 @@ sub servers_need_restart($) {
|
|||
|
||||
|
||||
|
||||
#
|
||||
# Return list of specific servers
|
||||
# - there is no servers in an empty config
|
||||
#
|
||||
sub _like { return $config ? $config->like($_[0]) : (); }
|
||||
sub mysqlds { return _like('mysqld.'); }
|
||||
sub ndbds { return _like('cluster_config.ndbd.');}
|
||||
sub ndb_mgmds { return _like('cluster_config.ndb_mgmd.'); }
|
||||
sub clusters { return _like('mysql_cluster.'); }
|
||||
sub all_servers { return ( mysqlds(), ndb_mgmds(), ndbds() ); }
|
||||
############################################
|
||||
|
||||
############################################
|
||||
|
||||
#
|
||||
# Filter a list of servers and return only those that are part
|
||||
|
@ -4921,18 +5072,6 @@ sub started { return grep(defined $_, map($_->{proc}, @_)); }
|
|||
sub stopped { return grep(!defined $_, map($_->{proc}, @_)); }
|
||||
|
||||
|
||||
sub envsubst {
|
||||
my $string= shift;
|
||||
|
||||
if ( ! defined $ENV{$string} )
|
||||
{
|
||||
mtr_error(".opt file references '$string' which is not set");
|
||||
}
|
||||
|
||||
return $ENV{$string};
|
||||
}
|
||||
|
||||
|
||||
sub get_extra_opts {
|
||||
my ($mysqld, $tinfo)= @_;
|
||||
|
||||
|
@ -4943,8 +5082,9 @@ sub get_extra_opts {
|
|||
# Expand environment variables
|
||||
foreach my $opt ( @$opts )
|
||||
{
|
||||
$opt =~ s/\$\{(\w+)\}/envsubst($1)/ge;
|
||||
$opt =~ s/\$(\w+)/envsubst($1)/ge;
|
||||
no warnings 'uninitialized';
|
||||
$opt =~ s/\$\{(\w+)\}/$ENV{$1}/ge;
|
||||
$opt =~ s/\$(\w+)/$ENV{$1}/ge;
|
||||
}
|
||||
return $opts;
|
||||
}
|
||||
|
@ -4953,28 +5093,10 @@ sub get_extra_opts {
|
|||
sub stop_servers($$) {
|
||||
my (@servers)= @_;
|
||||
|
||||
if ( join('|', @servers) eq join('|', all_servers()) )
|
||||
{
|
||||
# All servers are going down, use some kind of order to
|
||||
# avoid too many warnings in the log files
|
||||
mtr_report("Restarting ", started(@servers));
|
||||
|
||||
mtr_report("Restarting all servers");
|
||||
|
||||
# mysqld processes
|
||||
My::SafeProcess::shutdown( $opt_shutdown_timeout, started(mysqlds()) );
|
||||
|
||||
# cluster processes
|
||||
My::SafeProcess::shutdown( $opt_shutdown_timeout,
|
||||
started(ndbds(), ndb_mgmds()) );
|
||||
}
|
||||
else
|
||||
{
|
||||
mtr_report("Restarting ", started(@servers));
|
||||
|
||||
# Stop only some servers
|
||||
My::SafeProcess::shutdown( $opt_shutdown_timeout,
|
||||
started(@servers) );
|
||||
}
|
||||
My::SafeProcess::shutdown($opt_shutdown_timeout,
|
||||
started(@servers));
|
||||
|
||||
foreach my $server (@servers)
|
||||
{
|
||||
|
@ -5001,145 +5123,14 @@ sub stop_servers($$) {
|
|||
sub start_servers($) {
|
||||
my ($tinfo)= @_;
|
||||
|
||||
# Start clusters
|
||||
foreach my $cluster ( clusters() )
|
||||
{
|
||||
ndbcluster_start($cluster);
|
||||
for (all_servers()) {
|
||||
$_->{START}->($_, $tinfo) if $_->{START};
|
||||
}
|
||||
|
||||
# Start mysqlds
|
||||
foreach my $mysqld ( mysqlds() )
|
||||
{
|
||||
if ( $mysqld->{proc} )
|
||||
{
|
||||
# Already started
|
||||
|
||||
# Write start of testcase to log file
|
||||
mark_log($mysqld->value('#log-error'), $tinfo);
|
||||
|
||||
next;
|
||||
}
|
||||
|
||||
my $datadir= $mysqld->value('datadir');
|
||||
if ($opt_start_dirty)
|
||||
{
|
||||
# Don't delete anything if starting dirty
|
||||
;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
my @options= ('log-bin', 'relay-log');
|
||||
foreach my $option_name ( @options ) {
|
||||
next unless $mysqld->option($option_name);
|
||||
|
||||
my $file_name= $mysqld->value($option_name);
|
||||
next unless
|
||||
defined $file_name and
|
||||
-e $file_name;
|
||||
|
||||
mtr_debug(" -removing '$file_name'");
|
||||
unlink($file_name) or die ("unable to remove file '$file_name'");
|
||||
}
|
||||
|
||||
if (-d $datadir ) {
|
||||
preserve_error_log($mysqld);
|
||||
mtr_verbose(" - removing '$datadir'");
|
||||
rmtree($datadir);
|
||||
}
|
||||
}
|
||||
|
||||
my $mysqld_basedir= $mysqld->value('basedir');
|
||||
if ( $basedir eq $mysqld_basedir )
|
||||
{
|
||||
if (! $opt_start_dirty) # If dirty, keep possibly grown system db
|
||||
{
|
||||
# Copy datadir from installed system db
|
||||
for my $path ( "$opt_vardir", "$opt_vardir/..") {
|
||||
my $install_db= "$path/install.db";
|
||||
copytree($install_db, $datadir)
|
||||
if -d $install_db;
|
||||
}
|
||||
mtr_error("Failed to copy system db to '$datadir'")
|
||||
unless -d $datadir;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
mysql_install_db($mysqld); # For versional testing
|
||||
|
||||
mtr_error("Failed to install system db to '$datadir'")
|
||||
unless -d $datadir;
|
||||
|
||||
}
|
||||
restore_error_log($mysqld);
|
||||
|
||||
# Create the servers tmpdir
|
||||
my $tmpdir= $mysqld->value('tmpdir');
|
||||
mkpath($tmpdir) unless -d $tmpdir;
|
||||
|
||||
# Write start of testcase to log file
|
||||
mark_log($mysqld->value('#log-error'), $tinfo);
|
||||
|
||||
# Run <tname>-master.sh
|
||||
if ($mysqld->option('#!run-master-sh') and
|
||||
run_sh_script($tinfo->{master_sh}) )
|
||||
{
|
||||
$tinfo->{'comment'}= "Failed to execute '$tinfo->{master_sh}'";
|
||||
return 1;
|
||||
}
|
||||
|
||||
# Run <tname>-slave.sh
|
||||
if ($mysqld->option('#!run-slave-sh') and
|
||||
run_sh_script($tinfo->{slave_sh}))
|
||||
{
|
||||
$tinfo->{'comment'}= "Failed to execute '$tinfo->{slave_sh}'";
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (!$opt_embedded_server)
|
||||
{
|
||||
my $extra_opts= get_extra_opts($mysqld, $tinfo);
|
||||
mysqld_start($mysqld,$extra_opts);
|
||||
|
||||
# Save this test case information, so next can examine it
|
||||
$mysqld->{'started_tinfo'}= $tinfo;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
# Wait for clusters to start
|
||||
foreach my $cluster ( clusters() )
|
||||
{
|
||||
if (ndbcluster_wait_started($cluster, ""))
|
||||
{
|
||||
# failed to start
|
||||
$tinfo->{'comment'}= "Start of '".$cluster->name()."' cluster failed";
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
# Wait for mysqlds to start
|
||||
foreach my $mysqld ( mysqlds() )
|
||||
{
|
||||
next if !started($mysqld);
|
||||
|
||||
if (sleep_until_file_created($mysqld->value('pid-file'),
|
||||
$opt_start_timeout,
|
||||
$mysqld->{'proc'}) == 0) {
|
||||
$tinfo->{comment}=
|
||||
"Failed to start ".$mysqld->name();
|
||||
|
||||
my $logfile= $mysqld->value('#log-error');
|
||||
if ( defined $logfile and -f $logfile )
|
||||
{
|
||||
my @srv_lines= extract_server_log($logfile, $tinfo->{name});
|
||||
$tinfo->{logfile}= "Server log is:\n" . join ("", @srv_lines);
|
||||
}
|
||||
else
|
||||
{
|
||||
$tinfo->{logfile}= "Could not open server logfile: '$logfile'";
|
||||
}
|
||||
for (all_servers()) {
|
||||
next unless $_->{WAIT} and started($_);
|
||||
if ($_->{WAIT}->($_)) {
|
||||
$tinfo->{comment}= "Failed to start ".$_->name();
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
@ -5401,13 +5392,7 @@ sub gdb_arguments {
|
|||
else
|
||||
{
|
||||
# write init file for mysqld
|
||||
mtr_tofile($gdb_init_file,
|
||||
"set args $str\n" .
|
||||
"break mysql_parse\n" .
|
||||
"commands 1\n" .
|
||||
"disable 1\n" .
|
||||
"end\n" .
|
||||
"run");
|
||||
mtr_tofile($gdb_init_file, "set args $str\n");
|
||||
}
|
||||
|
||||
if ( $opt_manual_gdb )
|
||||
|
@ -5465,13 +5450,7 @@ sub ddd_arguments {
|
|||
else
|
||||
{
|
||||
# write init file for mysqld
|
||||
mtr_tofile($gdb_init_file,
|
||||
"file $$exe\n" .
|
||||
"set args $str\n" .
|
||||
"break mysql_parse\n" .
|
||||
"commands 1\n" .
|
||||
"disable 1\n" .
|
||||
"end");
|
||||
mtr_tofile($gdb_init_file, "file $$exe\nset args $str\n");
|
||||
}
|
||||
|
||||
if ( $opt_manual_ddd )
|
||||
|
@ -5853,3 +5832,25 @@ sub list_options ($) {
|
|||
|
||||
exit(1);
|
||||
}
|
||||
|
||||
sub time_format($) {
|
||||
sprintf '%d:%02d:%02d', $_[0]/3600, ($_[0]/60)%60, $_[0]%60;
|
||||
}
|
||||
|
||||
my $num_tests;
|
||||
|
||||
sub xterm_stat {
|
||||
if (-t STDOUT and $ENV{TERM} =~ /xterm/) {
|
||||
my ($left) = @_;
|
||||
|
||||
# 2.5 -> best by test
|
||||
$num_tests = $left + 2.5 unless $num_tests;
|
||||
|
||||
my $done = $num_tests - $left;
|
||||
my $spent = time - $^T;
|
||||
|
||||
printf "\e];mtr: spent %s on %d tests. %s (%d tests) left\a",
|
||||
time_format($spent), $done,
|
||||
time_format($spent/$done * $left), $left;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -841,11 +841,11 @@ call p_verify_status_increment(2, 0, 2, 0);
|
|||
SUCCESS
|
||||
|
||||
alter table t3 rename t4;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
SUCCESS
|
||||
|
||||
rename table t4 to t3;
|
||||
call p_verify_status_increment(2, 2, 2, 2);
|
||||
call p_verify_status_increment(1, 0, 1, 0);
|
||||
SUCCESS
|
||||
|
||||
truncate table t3;
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
drop database if exists events_test;
|
||||
drop database if exists events_test2;
|
||||
drop table if exists t1;
|
||||
CREATE TABLE t1 (
|
||||
Period smallint(4) unsigned zerofill DEFAULT '0000' NOT NULL,
|
||||
Varor_period smallint(4) unsigned DEFAULT '0' NOT NULL
|
||||
) ENGINE=example;
|
||||
drop table t1;
|
|
@ -995,6 +995,7 @@ SELECT 1 FROM
|
|||
1
|
||||
1
|
||||
DROP TABLE t1;
|
||||
End of 5.0 tests
|
||||
#
|
||||
# Bug #52397: another crash with explain extended and group_concat
|
||||
#
|
||||
|
@ -1010,4 +1011,22 @@ id select_type table type possible_keys key key_len ref rows filtered Extra
|
|||
Warnings:
|
||||
Note 1003 select 1 AS `1` from (select group_concat(`test`.`t1`.`a` order by `test`.`t1`.`a` ASC separator ',') AS `GROUP_CONCAT(t1.a ORDER BY t1.a ASC)` from `test`.`t1` `t2` join `test`.`t1` group by `test`.`t1`.`a`) `d`
|
||||
DROP TABLE t1;
|
||||
End of 5.0 tests
|
||||
#
|
||||
# Bug #54476: crash when group_concat and 'with rollup' in prepared statements
|
||||
#
|
||||
CREATE TABLE t1 (a INT);
|
||||
INSERT INTO t1 VALUES (1), (2);
|
||||
PREPARE stmt FROM "SELECT GROUP_CONCAT(t1.a ORDER BY t1.a) FROM t1 JOIN t1 t2 GROUP BY t1.a WITH ROLLUP";
|
||||
EXECUTE stmt;
|
||||
GROUP_CONCAT(t1.a ORDER BY t1.a)
|
||||
1,1
|
||||
2,2
|
||||
1,1,2,2
|
||||
EXECUTE stmt;
|
||||
GROUP_CONCAT(t1.a ORDER BY t1.a)
|
||||
1,1
|
||||
2,2
|
||||
1,1,2,2
|
||||
DEALLOCATE PREPARE stmt;
|
||||
DROP TABLE t1;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -243,4 +243,19 @@ End of 5.0 tests
|
|||
select connection_id() > 0;
|
||||
connection_id() > 0
|
||||
1
|
||||
#
|
||||
# Bug #54461: crash with longblob and union or update with subquery
|
||||
#
|
||||
CREATE TABLE t1 (a INT, b LONGBLOB);
|
||||
INSERT INTO t1 VALUES (1, '2'), (2, '3'), (3, '2');
|
||||
SELECT DISTINCT LEAST(a, (SELECT b FROM t1 LIMIT 1)) FROM t1 UNION SELECT 1;
|
||||
LEAST(a, (SELECT b FROM t1 LIMIT 1))
|
||||
1
|
||||
2
|
||||
SELECT DISTINCT GREATEST(a, (SELECT b FROM t1 LIMIT 1)) FROM t1 UNION SELECT 1;
|
||||
GREATEST(a, (SELECT b FROM t1 LIMIT 1))
|
||||
2
|
||||
3
|
||||
1
|
||||
DROP TABLE t1;
|
||||
End of tests
|
||||
|
|
|
@ -1809,5 +1809,57 @@ SELECT MAX(t2.a) FROM t2 LEFT JOIN t1 ON t2.a = t1.a;
|
|||
MAX(t2.a)
|
||||
2
|
||||
DROP TABLE t1, t2;
|
||||
CREATE TABLE t1 (a int(11) NOT NULL);
|
||||
INSERT INTO t1 VALUES (1),(2);
|
||||
CREATE TABLE t2 (
|
||||
key_col int(11) NOT NULL,
|
||||
KEY (key_col)
|
||||
);
|
||||
INSERT INTO t2 VALUES (1),(2);
|
||||
select min(t2.key_col) from t1,t2 where t1.a=1;
|
||||
min(t2.key_col)
|
||||
1
|
||||
select min(t2.key_col) from t1,t2 where t1.a > 1000;
|
||||
min(t2.key_col)
|
||||
NULL
|
||||
select min(t2.key_col)+1 from t1,t2 where t1.a> 1000;
|
||||
min(t2.key_col)+1
|
||||
NULL
|
||||
drop table t1,t2;
|
||||
#
|
||||
# Bug#55188: GROUP BY, GROUP_CONCAT and TEXT - inconsistent results
|
||||
#
|
||||
CREATE TABLE t1 (a text, b varchar(10));
|
||||
INSERT INTO t1 VALUES (repeat('1', 1300),'one'), (repeat('1', 1300),'two');
|
||||
EXPLAIN
|
||||
SELECT SUBSTRING(a,1,10), LENGTH(a), GROUP_CONCAT(b) FROM t1 GROUP BY a;
|
||||
id 1
|
||||
select_type SIMPLE
|
||||
table t1
|
||||
type ALL
|
||||
possible_keys NULL
|
||||
key NULL
|
||||
key_len NULL
|
||||
ref NULL
|
||||
rows 2
|
||||
Extra Using filesort
|
||||
SELECT SUBSTRING(a,1,10), LENGTH(a), GROUP_CONCAT(b) FROM t1 GROUP BY a;
|
||||
SUBSTRING(a,1,10) LENGTH(a) GROUP_CONCAT(b)
|
||||
1111111111 1300 one,two
|
||||
EXPLAIN
|
||||
SELECT SUBSTRING(a,1,10), LENGTH(a) FROM t1 GROUP BY a;
|
||||
id 1
|
||||
select_type SIMPLE
|
||||
table t1
|
||||
type ALL
|
||||
possible_keys NULL
|
||||
key NULL
|
||||
key_len NULL
|
||||
ref NULL
|
||||
rows 2
|
||||
Extra Using temporary; Using filesort
|
||||
SELECT SUBSTRING(a,1,10), LENGTH(a) FROM t1 GROUP BY a;
|
||||
SUBSTRING(a,1,10) LENGTH(a)
|
||||
1111111111 1300
|
||||
DROP TABLE t1;
|
||||
# End of 5.1 tests
|
||||
|
|
|
@ -470,10 +470,9 @@ WHERE table2.f1 = 2
|
|||
GROUP BY table1.f1, table2.f2
|
||||
HAVING (table2.f2 = 8 AND table1.f1 >= 6);
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE table2 const PRIMARY PRIMARY 4 const 1 100.00 Using filesort
|
||||
1 SIMPLE table1 ALL NULL NULL NULL NULL 4 100.00 Using where
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL Impossible HAVING noticed after reading const tables
|
||||
Warnings:
|
||||
Note 1003 select `test`.`table1`.`f1` AS `f1`,'7' AS `f2` from `test`.`t1` `table1` join `test`.`t1` `table2` where ((`test`.`table1`.`f3` = '9')) group by `test`.`table1`.`f1`,'7' having (('7' = 8) and (`test`.`table1`.`f1` >= 6))
|
||||
Note 1003 select `test`.`table1`.`f1` AS `f1`,'7' AS `f2` from `test`.`t1` `table1` join `test`.`t1` `table2` where ((`test`.`table1`.`f3` = '9')) group by `test`.`table1`.`f1`,'7' having 0
|
||||
EXPLAIN EXTENDED
|
||||
SELECT table1.f1, table2.f2
|
||||
FROM t1 AS table1
|
||||
|
@ -482,10 +481,9 @@ WHERE table2.f1 = 2
|
|||
GROUP BY table1.f1, table2.f2
|
||||
HAVING (table2.f2 = 8);
|
||||
id select_type table type possible_keys key key_len ref rows filtered Extra
|
||||
1 SIMPLE table2 const PRIMARY PRIMARY 4 const 1 100.00 Using filesort
|
||||
1 SIMPLE table1 ALL NULL NULL NULL NULL 4 100.00 Using where
|
||||
1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL Impossible HAVING noticed after reading const tables
|
||||
Warnings:
|
||||
Note 1003 select `test`.`table1`.`f1` AS `f1`,'7' AS `f2` from `test`.`t1` `table1` join `test`.`t1` `table2` where ((`test`.`table1`.`f3` = '9')) group by `test`.`table1`.`f1`,'7' having ('7' = 8)
|
||||
Note 1003 select `test`.`table1`.`f1` AS `f1`,'7' AS `f2` from `test`.`t1` `table1` join `test`.`t1` `table2` where ((`test`.`table1`.`f3` = '9')) group by `test`.`table1`.`f1`,'7' having 0
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug#52336 Segfault / crash in 5.1 copy_fields (param=0x9872980) at sql_select.cc:15355
|
||||
|
@ -532,3 +530,19 @@ MAX(t2.f2)
|
|||
NULL
|
||||
DROP TABLE t1,t2;
|
||||
End of 5.0 tests
|
||||
#
|
||||
# Bug#54416 MAX from JOIN with HAVING returning NULL with 5.1 and Empty set
|
||||
#
|
||||
CREATE TABLE t1 (f1 INT(11), f2 VARCHAR(1), PRIMARY KEY (f1));
|
||||
INSERT INTO t1 VALUES (1,'f');
|
||||
CREATE TABLE t2 (f1 INT(11), f2 VARCHAR(1));
|
||||
INSERT INTO t2 VALUES (2,'m');
|
||||
INSERT INTO t2 VALUES (3,'m');
|
||||
INSERT INTO t2 VALUES (11,NULL);
|
||||
INSERT INTO t2 VALUES (12,'k');
|
||||
SELECT MAX(t1.f1) field1
|
||||
FROM t1 JOIN t2 ON t2.f2 LIKE 'x'
|
||||
HAVING field1 < 7;
|
||||
field1
|
||||
DROP TABLE t1,t2;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -1651,4 +1651,21 @@ WHERE INFORMATION_SCHEMA.COLUMNS.TABLE_NAME = 'variables';
|
|||
COLUMN_DEFAULT TABLE_NAME
|
||||
NULL variables
|
||||
DROP TABLE variables;
|
||||
#
|
||||
# Bug #53814: NUMERIC_PRECISION for unsigned bigint field is 19,
|
||||
# should be 20
|
||||
#
|
||||
CREATE TABLE ubig (a BIGINT, b BIGINT UNSIGNED);
|
||||
SELECT TABLE_NAME, COLUMN_NAME, NUMERIC_PRECISION
|
||||
FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='ubig';
|
||||
TABLE_NAME COLUMN_NAME NUMERIC_PRECISION
|
||||
ubig a 19
|
||||
ubig b 20
|
||||
INSERT INTO ubig VALUES (0xFFFFFFFFFFFFFFFF,0xFFFFFFFFFFFFFFFF);
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'a' at row 1
|
||||
SELECT length(CAST(b AS CHAR)) FROM ubig;
|
||||
length(CAST(b AS CHAR))
|
||||
20
|
||||
DROP TABLE ubig;
|
||||
End of 5.1 tests.
|
||||
|
|
|
@ -503,4 +503,33 @@ DROP TABLE t1;
|
|||
CREATE TABLE t1 (id INT NOT NULL);
|
||||
LOAD DATA LOCAL INFILE 'tb.txt' INTO TABLE t1;
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #51876 : crash/memory underrun when loading data with ucs2
|
||||
# and reverse() function
|
||||
#
|
||||
# Problem # 1 (original report): wrong parsing of ucs2 data
|
||||
SELECT '00' UNION SELECT '10' INTO OUTFILE 'tmpp.txt';
|
||||
CREATE TABLE t1(a INT);
|
||||
LOAD DATA INFILE 'tmpp.txt' INTO TABLE t1 CHARACTER SET ucs2
|
||||
(@b) SET a=REVERSE(@b);
|
||||
Warnings:
|
||||
Warning 1366 Incorrect integer value: '00' for column 'a' at row 1
|
||||
Warning 1366 Incorrect integer value: '10' for column 'a' at row 2
|
||||
# should return 2 zeroes (as the value is truncated)
|
||||
SELECT * FROM t1;
|
||||
a
|
||||
0
|
||||
0
|
||||
DROP TABLE t1;
|
||||
# Problem # 2 : if you write and read ucs2 data to a file they're lost
|
||||
SELECT '00' UNION SELECT '10' INTO OUTFILE 'tmpp2.txt' CHARACTER SET ucs2;
|
||||
CREATE TABLE t1(a INT);
|
||||
LOAD DATA INFILE 'tmpp2.txt' INTO TABLE t1 CHARACTER SET ucs2
|
||||
(@b) SET a=REVERSE(@b);
|
||||
# should return 0 and 1 (10 reversed)
|
||||
SELECT * FROM t1;
|
||||
a
|
||||
0
|
||||
1
|
||||
DROP TABLE t1;
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -56,6 +56,7 @@ CREATE DATABASE `TEST_$1`;
|
|||
SHOW DATABASES LIKE "TEST%";
|
||||
Database (TEST%)
|
||||
TEST_$1
|
||||
test
|
||||
DROP DATABASE `test_$1`;
|
||||
CREATE TABLE T1 (a int) engine=innodb;
|
||||
INSERT INTO T1 VALUES (1);
|
||||
|
@ -171,6 +172,6 @@ create table myUC (i int);
|
|||
select TABLE_SCHEMA,TABLE_NAME FROM information_schema.TABLES
|
||||
where TABLE_SCHEMA ='mysqltest_LC2';
|
||||
TABLE_SCHEMA TABLE_NAME
|
||||
mysqltest_LC2 myUC
|
||||
mysqltest_lc2 myUC
|
||||
use test;
|
||||
drop database mysqltest_LC2;
|
||||
|
|
|
@ -148,3 +148,20 @@ a
|
|||
DROP VIEW v1;
|
||||
DROP TABLE t1;
|
||||
End of 5.0 tests.
|
||||
#
|
||||
# Bug #53095: SELECT column_name FROM INFORMATION_SCHEMA.STATISTICS
|
||||
# returns nothing
|
||||
#
|
||||
CREATE TABLE `ttt` (
|
||||
`f1` char(3) NOT NULL,
|
||||
PRIMARY KEY (`f1`)
|
||||
) ENGINE=myisam DEFAULT CHARSET=latin1;
|
||||
SELECT count(COLUMN_NAME) FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME =
|
||||
'TTT';
|
||||
count(COLUMN_NAME)
|
||||
1
|
||||
SELECT count(*) FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_NAME = 'TTT';
|
||||
count(*)
|
||||
1
|
||||
DROP TABLE `ttt`;
|
||||
End of 5.0 tests.
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
SET @old_general_log= @@global.general_log;
|
||||
SET @old_slow_query_log= @@global.slow_query_log;
|
||||
ok
|
||||
SET @@global.general_log= @old_general_log;
|
||||
SET @@global.slow_query_log= @old_slow_query_log;
|
||||
|
|
|
@ -169,3 +169,45 @@ DROP PROCEDURE testproc;
|
|||
WARNING: NULL values of the 'character_set_client' column ('mysql.proc' table) have been updated with a default value (latin1). Please verify if necessary.
|
||||
WARNING: NULL values of the 'collation_connection' column ('mysql.proc' table) have been updated with a default value (latin1_swedish_ci). Please verify if necessary.
|
||||
WARNING: NULL values of the 'db_collation' column ('mysql.proc' table) have been updated with default values. Please verify if necessary.
|
||||
#
|
||||
# Bug #53613: mysql_upgrade incorrectly revokes
|
||||
# TRIGGER privilege on given table
|
||||
#
|
||||
GRANT USAGE ON *.* TO 'user3'@'%';
|
||||
GRANT ALL PRIVILEGES ON `roelt`.`test2` TO 'user3'@'%';
|
||||
Run mysql_upgrade with all privileges on a user
|
||||
mtr.global_suppressions OK
|
||||
mtr.test_suppressions OK
|
||||
mysql.columns_priv OK
|
||||
mysql.db OK
|
||||
mysql.event OK
|
||||
mysql.func OK
|
||||
mysql.general_log
|
||||
Error : You can't use locks with log tables.
|
||||
status : OK
|
||||
mysql.help_category OK
|
||||
mysql.help_keyword OK
|
||||
mysql.help_relation OK
|
||||
mysql.help_topic OK
|
||||
mysql.host OK
|
||||
mysql.ndb_binlog_index OK
|
||||
mysql.plugin OK
|
||||
mysql.proc OK
|
||||
mysql.procs_priv OK
|
||||
mysql.servers OK
|
||||
mysql.slow_log
|
||||
Error : You can't use locks with log tables.
|
||||
status : OK
|
||||
mysql.tables_priv OK
|
||||
mysql.time_zone OK
|
||||
mysql.time_zone_leap_second OK
|
||||
mysql.time_zone_name OK
|
||||
mysql.time_zone_transition OK
|
||||
mysql.time_zone_transition_type OK
|
||||
mysql.user OK
|
||||
SHOW GRANTS FOR 'user3'@'%';
|
||||
Grants for user3@%
|
||||
GRANT USAGE ON *.* TO 'user3'@'%'
|
||||
GRANT ALL PRIVILEGES ON `roelt`.`test2` TO 'user3'@'%'
|
||||
DROP USER 'user3'@'%';
|
||||
End of 5.1 tests
|
||||
|
|
|
@ -59,3 +59,26 @@ FROM t3 WHERE 1 = 0 GROUP BY 1;
|
|||
(SELECT 1 FROM t1,t2 WHERE t2.b > t3.b)
|
||||
DROP TABLE t1,t2,t3;
|
||||
End of 5.0 tests.
|
||||
CREATE TABLE t1 (col_int_nokey int(11) NOT NULL, col_varchar_nokey varchar(1) NOT NULL) engine=myisam;
|
||||
INSERT INTO t1 VALUES (2,'s'),(0,'v'),(2,'s');
|
||||
CREATE TABLE t2 (
|
||||
pk int(11) NOT NULL AUTO_INCREMENT,
|
||||
`col_int_key` int(11) NOT NULL,
|
||||
col_varchar_key varchar(1) NOT NULL,
|
||||
PRIMARY KEY (pk),
|
||||
KEY `col_int_key` (`col_int_key`),
|
||||
KEY `col_varchar_key` (`col_varchar_key`)
|
||||
) ENGINE=MyISAM;
|
||||
INSERT INTO t2 VALUES (4,10,'g'), (5,20,'v');
|
||||
SELECT t1.col_int_nokey,(SELECT MIN( t2_a.col_int_key ) FROM t2 t2_a, t2 t2_b, t1 t1_a WHERE t1_a.col_varchar_nokey = t2_b.col_varchar_key and t1.col_int_nokey ) as sub FROM t1;
|
||||
col_int_nokey sub
|
||||
2 10
|
||||
0 NULL
|
||||
2 10
|
||||
SELECT t1.col_int_nokey,(SELECT MIN( t2_a.col_int_key ) +1 FROM t2 t2_a, t2 t2_b, t1 t1_a WHERE t1_a.col_varchar_nokey = t2_b.col_varchar_key and t1.col_int_nokey ) as sub FROM t1;
|
||||
col_int_nokey sub
|
||||
2 11
|
||||
0 NULL
|
||||
2 11
|
||||
DROP TABLE t1,t2;
|
||||
End of 5.1 tests.
|
||||
|
|
|
@ -527,3 +527,17 @@ ERROR HY000: You are using safe update mode and you tried to update a table with
|
|||
SET SESSION sql_safe_updates = DEFAULT;
|
||||
DROP TABLE t1;
|
||||
DROP VIEW v1;
|
||||
#
|
||||
# Bug#54734 assert in Diagnostics_area::set_ok_status
|
||||
#
|
||||
DROP TABLE IF EXISTS t1, not_exists;
|
||||
DROP FUNCTION IF EXISTS f1;
|
||||
DROP VIEW IF EXISTS v1;
|
||||
CREATE TABLE t1 (PRIMARY KEY(pk)) AS SELECT 1 AS pk;
|
||||
CREATE FUNCTION f1() RETURNS INTEGER RETURN (SELECT 1 FROM not_exists);
|
||||
CREATE VIEW v1 AS SELECT pk FROM t1 WHERE f1() = 13;
|
||||
UPDATE v1 SET pk = 7 WHERE pk > 0;
|
||||
ERROR HY000: View 'test.v1' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
|
||||
DROP VIEW v1;
|
||||
DROP FUNCTION f1;
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -1,15 +1,14 @@
|
|||
create table t1 (id int) engine=NDB;
|
||||
create table t1 (id int) engine=InnoDB;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NDB'
|
||||
Warning 1286 Unknown table engine 'InnoDB'
|
||||
Warning 1266 Using storage engine MyISAM for table 't1'
|
||||
alter table t1 engine=NDB;
|
||||
alter table t1 engine=InnoDB;
|
||||
Warnings:
|
||||
Warning 1286 Unknown table engine 'NDB'
|
||||
Warning 1286 Unknown table engine 'InnoDB'
|
||||
drop table t1;
|
||||
SELECT ENGINE, SUPPORT FROM INFORMATION_SCHEMA.ENGINES WHERE ENGINE='ndbcluster';
|
||||
SELECT ENGINE, SUPPORT FROM INFORMATION_SCHEMA.ENGINES WHERE ENGINE='InnoDB';
|
||||
ENGINE SUPPORT
|
||||
ndbcluster NO
|
||||
SELECT PLUGIN_NAME, PLUGIN_STATUS FROM INFORMATION_SCHEMA.PLUGINS WHERE
|
||||
PLUGIN_NAME='ndbcluster';
|
||||
InnoDB NO
|
||||
SELECT PLUGIN_NAME, PLUGIN_STATUS FROM INFORMATION_SCHEMA.PLUGINS WHERE PLUGIN_NAME='InnoDB';
|
||||
PLUGIN_NAME PLUGIN_STATUS
|
||||
ndbcluster DISABLED
|
||||
InnoDB DISABLED
|
||||
|
|
|
@ -1,125 +1,51 @@
|
|||
Certificate:
|
||||
Data:
|
||||
Version: 1 (0x0)
|
||||
Serial Number: 1048579 (0x100003)
|
||||
Signature Algorithm: md5WithRSAEncryption
|
||||
Issuer: C=SE, ST=Uppsala, L=Uppsala, O=MySQL AB
|
||||
Validity
|
||||
Not Before: Jan 29 12:01:53 2010 GMT
|
||||
Not After : Jan 28 12:01:53 2015 GMT
|
||||
Subject: C=SE, ST=Uppsala, O=MySQL AB, CN=server
|
||||
Subject Public Key Info:
|
||||
Public Key Algorithm: rsaEncryption
|
||||
Public-Key: (8192 bit)
|
||||
Modulus:
|
||||
00:ca:aa:1d:c4:11:ec:91:f0:c7:ff:5f:90:92:fc:
|
||||
40:0c:5e:b7:3d:00:c5:20:d5:0f:89:31:07:d7:41:
|
||||
4c:8b:60:80:aa:38:14:de:93:6b:9c:74:88:41:68:
|
||||
b5:02:41:01:2d:86:a2:7a:95:53:5e:7b:67:2f:6c:
|
||||
1e:29:51:f9:44:fd:4a:80:be:b2:23:a1:3e:1b:38:
|
||||
cf:88:c4:71:ee:f8:6b:41:c5:2d:c0:c3:52:ac:59:
|
||||
7d:81:34:19:95:32:b8:9a:51:b6:41:36:d4:c4:a1:
|
||||
ae:84:e6:38:b9:e8:bf:96:be:19:7a:6b:77:4d:e0:
|
||||
de:e6:b3:b6:6b:bc:3d:dd:68:bc:4b:c4:eb:f5:36:
|
||||
93:ed:56:a2:15:50:8a:10:e8:d6:22:ed:6c:b1:cd:
|
||||
c3:18:c9:f6:0a:e1:de:61:65:62:d6:14:41:8c:b5:
|
||||
fb:14:68:c1:cf:12:5d:41:21:9d:57:11:43:7d:bb:
|
||||
43:2c:21:bb:c3:44:7d:a8:cf:1f:c3:71:75:b5:47:
|
||||
c2:7d:ce:38:3c:73:64:9e:15:d8:a7:27:cf:bd:40:
|
||||
c8:45:08:e3:c8:39:a8:0b:8e:c2:5b:7b:f1:47:91:
|
||||
12:91:cc:e1:00:e0:94:5b:bd:32:e4:0c:8d:c3:be:
|
||||
cc:76:32:52:12:69:b0:18:e0:b0:c2:76:34:5a:5f:
|
||||
79:d9:f6:81:9d:02:0a:61:69:1c:33:ce:49:fa:76:
|
||||
03:1e:07:5b:27:0b:bf:34:9e:34:96:b8:03:9b:50:
|
||||
3a:6a:2f:17:7a:14:cf:65:63:00:37:52:a8:73:ce:
|
||||
4b:14:40:f4:d2:9a:56:54:33:b8:77:2e:42:5b:8f:
|
||||
ec:1f:18:f4:ad:ab:8a:4a:8d:6d:70:25:f3:58:e7:
|
||||
cb:66:51:14:7d:16:f4:eb:6d:56:76:76:51:6e:d6:
|
||||
1d:da:d3:8d:c0:64:5a:67:4e:af:e2:bf:33:d1:b8:
|
||||
f6:2a:fc:57:87:a7:35:5e:80:c9:ac:fc:87:c9:71:
|
||||
17:91:bf:b7:4d:a3:ed:3c:1b:27:f4:66:a0:f9:46:
|
||||
03:27:cc:ea:80:f6:4b:40:f6:41:94:cd:bd:0a:b3:
|
||||
ef:26:be:de:6f:69:ae:0f:3f:1c:55:63:33:90:9b:
|
||||
ed:ca:5a:12:4d:de:4b:06:c2:a2:92:b0:42:3d:31:
|
||||
af:a4:15:12:15:f8:8a:e9:88:8d:cf:fd:85:66:50:
|
||||
6f:11:f1:9f:48:f3:b5:ba:9d:86:68:24:a2:5d:a8:
|
||||
7c:54:42:fa:d8:b5:c5:f2:dd:0e:0f:d0:68:e4:54:
|
||||
7e:c5:b9:a0:9b:65:2d:77:f4:8f:b9:30:0a:d5:86:
|
||||
5c:ed:c9:7c:d1:da:9d:0d:63:50:ee:e5:1e:92:63:
|
||||
cc:a2:0c:e8:4a:96:02:4d:dc:8f:df:7c:8f:08:18:
|
||||
a8:30:88:d7:af:89:ad:fc:57:4b:10:f9:f1:cb:48:
|
||||
e8:b6:3b:c8:3f:fc:c2:d3:d1:4a:10:3c:1b:6b:64:
|
||||
dc:e5:65:1e:5b:b2:da:b1:e2:24:97:8f:ee:c0:4b:
|
||||
8e:18:83:7c:17:a6:3c:45:b3:60:06:23:f2:2f:18:
|
||||
13:9e:17:8a:c6:72:79:8c:4d:04:f3:9d:ea:e0:25:
|
||||
d3:33:8c:1e:11:47:63:1f:a5:45:3f:bd:85:b3:fe:
|
||||
a5:68:ee:48:b7:0c:a4:c9:7f:72:d0:75:66:9b:6a:
|
||||
f9:a0:50:f3:a8:59:6d:a3:dd:38:4f:70:2b:bb:ff:
|
||||
92:2e:71:ab:ef:e9:00:ed:0d:d1:b4:6f:f0:8e:b2:
|
||||
09:fb:4d:61:0d:d9:10:d5:54:11:cd:03:94:84:fd:
|
||||
a8:68:e4:45:6e:1e:6a:1e:2f:85:a1:6d:f5:b6:c0:
|
||||
f1:ee:f7:36:e9:fe:c2:f7:ad:cc:13:46:5b:88:42:
|
||||
f0:2d:1f:b5:0e:7e:b5:2b:e4:8d:ab:b9:87:30:6a:
|
||||
3d:12:f4:ad:f3:1c:ac:cc:1a:48:29:2a:96:7b:80:
|
||||
00:0b:6e:59:87:bf:a3:ca:70:99:1b:1c:fd:72:3d:
|
||||
b2:d3:94:4a:cf:55:75:be:1f:40:ec:55:35:48:2d:
|
||||
55:f0:00:da:3c:b0:60:ba:11:32:66:54:0b:be:06:
|
||||
a4:5e:b7:c9:59:bb:4d:f4:92:06:26:48:6e:c2:12:
|
||||
d4:7c:f0:20:b8:a2:e1:bc:6a:b6:19:0e:37:47:55:
|
||||
c9:f2:49:0d:96:75:a2:84:64:bf:34:fc:be:b2:41:
|
||||
e4:f5:88:eb:e1:b7:26:a5:e5:41:c2:20:0c:f6:e2:
|
||||
a8:a5:e7:76:54:a5:fb:4b:80:05:7d:18:85:7a:ba:
|
||||
bc:b7:ad:c0:2f:60:85:cc:15:12:1c:2f:0a:9e:f3:
|
||||
7c:40:cf:f4:3e:23:d2:95:ca:d0:06:58:52:f0:84:
|
||||
d8:0f:3d:eb:ff:12:68:94:79:8f:be:40:29:5f:98:
|
||||
c8:90:6c:05:2f:99:8c:2a:63:78:1f:23:b1:29:c5:
|
||||
e7:49:c9:b2:92:0f:53:0b:d5:71:28:17:c2:19:bf:
|
||||
60:bf:7c:87:a8:ab:c1:f4:0a:c1:b8:d2:68:ee:c1:
|
||||
ce:a7:13:13:17:6d:24:5d:a2:37:a6:d7:7d:48:8b:
|
||||
2b:74:2d:40:2e:ca:19:d5:b6:3e:6c:42:71:fa:cf:
|
||||
85:87:f9:de:80:73:8b:89:f4:70:f0:d8:d7:ff:40:
|
||||
41:9c:c7:15:6d:9b:6e:4c:b5:52:02:99:79:32:73:
|
||||
ca:26:a0:ac:31:6f:c4:b0:f5:da:bb:c2:1f:e0:9f:
|
||||
44:ba:25:f7:9f
|
||||
Exponent: 65537 (0x10001)
|
||||
Signature Algorithm: md5WithRSAEncryption
|
||||
08:75:dc:b9:3f:aa:b6:7e:81:7a:39:d1:ee:ed:44:b6:ce:1b:
|
||||
37:c4:4c:19:d0:66:e6:eb:b5:4f:2a:ef:95:58:64:21:55:01:
|
||||
12:30:ac:8a:95:d1:06:de:29:46:a4:f1:7d:7f:b0:1e:d2:4e:
|
||||
fb:f6:fa:9a:74:be:85:62:db:0b:82:90:58:62:c5:5f:f1:80:
|
||||
02:9f:c5:fb:f3:6b:b0:b4:3b:04:b1:e5:53:c2:d0:00:a1:1a:
|
||||
9d:65:60:6f:73:98:67:e0:9c:c8:12:94:79:59:bf:43:7b:f5:
|
||||
77:c8:8f:df:b1:cd:11:1c:01:19:99:c2:22:42:f7:41:ae:b4:
|
||||
b8:1a
|
||||
-----BEGIN CERTIFICATE-----
|
||||
MIIFfDCCBOUCAxAAAzANBgkqhkiG9w0BAQQFADBEMQswCQYDVQQGEwJTRTEQMA4G
|
||||
A1UECBMHVXBwc2FsYTEQMA4GA1UEBxMHVXBwc2FsYTERMA8GA1UEChMITXlTUUwg
|
||||
QUIwHhcNMTAwMTI5MTIwMTUzWhcNMTUwMTI4MTIwMTUzWjBDMQswCQYDVQQGEwJT
|
||||
RTEQMA4GA1UECBMHVXBwc2FsYTERMA8GA1UEChMITXlTUUwgQUIxDzANBgNVBAMT
|
||||
BnNlcnZlcjCCBCIwDQYJKoZIhvcNAQEBBQADggQPADCCBAoCggQBAMqqHcQR7JHw
|
||||
x/9fkJL8QAxetz0AxSDVD4kxB9dBTItggKo4FN6Ta5x0iEFotQJBAS2GonqVU157
|
||||
Zy9sHilR+UT9SoC+siOhPhs4z4jEce74a0HFLcDDUqxZfYE0GZUyuJpRtkE21MSh
|
||||
roTmOLnov5a+GXprd03g3uaztmu8Pd1ovEvE6/U2k+1WohVQihDo1iLtbLHNwxjJ
|
||||
9grh3mFlYtYUQYy1+xRowc8SXUEhnVcRQ327Qywhu8NEfajPH8NxdbVHwn3OODxz
|
||||
ZJ4V2Kcnz71AyEUI48g5qAuOwlt78UeREpHM4QDglFu9MuQMjcO+zHYyUhJpsBjg
|
||||
sMJ2NFpfedn2gZ0CCmFpHDPOSfp2Ax4HWycLvzSeNJa4A5tQOmovF3oUz2VjADdS
|
||||
qHPOSxRA9NKaVlQzuHcuQluP7B8Y9K2rikqNbXAl81jny2ZRFH0W9OttVnZ2UW7W
|
||||
HdrTjcBkWmdOr+K/M9G49ir8V4enNV6Ayaz8h8lxF5G/t02j7TwbJ/RmoPlGAyfM
|
||||
6oD2S0D2QZTNvQqz7ya+3m9prg8/HFVjM5Cb7cpaEk3eSwbCopKwQj0xr6QVEhX4
|
||||
iumIjc/9hWZQbxHxn0jztbqdhmgkol2ofFRC+ti1xfLdDg/QaORUfsW5oJtlLXf0
|
||||
j7kwCtWGXO3JfNHanQ1jUO7lHpJjzKIM6EqWAk3cj998jwgYqDCI16+JrfxXSxD5
|
||||
8ctI6LY7yD/8wtPRShA8G2tk3OVlHluy2rHiJJeP7sBLjhiDfBemPEWzYAYj8i8Y
|
||||
E54XisZyeYxNBPOd6uAl0zOMHhFHYx+lRT+9hbP+pWjuSLcMpMl/ctB1Zptq+aBQ
|
||||
86hZbaPdOE9wK7v/ki5xq+/pAO0N0bRv8I6yCftNYQ3ZENVUEc0DlIT9qGjkRW4e
|
||||
ah4vhaFt9bbA8e73Nun+wvetzBNGW4hC8C0ftQ5+tSvkjau5hzBqPRL0rfMcrMwa
|
||||
SCkqlnuAAAtuWYe/o8pwmRsc/XI9stOUSs9Vdb4fQOxVNUgtVfAA2jywYLoRMmZU
|
||||
C74GpF63yVm7TfSSBiZIbsIS1HzwILii4bxqthkON0dVyfJJDZZ1ooRkvzT8vrJB
|
||||
5PWI6+G3JqXlQcIgDPbiqKXndlSl+0uABX0YhXq6vLetwC9ghcwVEhwvCp7zfEDP
|
||||
9D4j0pXK0AZYUvCE2A896/8SaJR5j75AKV+YyJBsBS+ZjCpjeB8jsSnF50nJspIP
|
||||
UwvVcSgXwhm/YL98h6irwfQKwbjSaO7BzqcTExdtJF2iN6bXfUiLK3QtQC7KGdW2
|
||||
PmxCcfrPhYf53oBzi4n0cPDY1/9AQZzHFW2bbky1UgKZeTJzyiagrDFvxLD12rvC
|
||||
H+CfRLol958CAwEAATANBgkqhkiG9w0BAQQFAAOBgQAIddy5P6q2foF6OdHu7US2
|
||||
zhs3xEwZ0Gbm67VPKu+VWGQhVQESMKyKldEG3ilGpPF9f7Ae0k779vqadL6FYtsL
|
||||
gpBYYsVf8YACn8X782uwtDsEseVTwtAAoRqdZWBvc5hn4JzIEpR5Wb9De/V3yI/f
|
||||
sc0RHAEZmcIiQvdBrrS4Gg==
|
||||
MIIJFDCCBPwCAQEwDQYJKoZIhvcNAQEEBQAwTjELMAkGA1UEBhMCU0UxEDAOBgNV
|
||||
BAgTB1VwcHNhbGExETAPBgNVBAoTCE15U1FMIEFCMQ0wCwYDVQQLEwRUZXN0MQsw
|
||||
CQYDVQQDEwJDQTAeFw0xMDA3MjgxNDA3MjhaFw0xODEwMTQxNDA3MjhaMFIxCzAJ
|
||||
BgNVBAYTAlNFMRAwDgYDVQQIEwdVcHBzYWxhMREwDwYDVQQKEwhNeVNRTCBBQjEN
|
||||
MAsGA1UECxMEVGVzdDEPMA0GA1UEAxMGc2VydmVyMIIEIjANBgkqhkiG9w0BAQEF
|
||||
AAOCBA8AMIIECgKCBAEA6h3v1OWb9I9U/Z8diBu/xYGS8NCTD3ZESboHxVI2qSEC
|
||||
PgxNNcG8Lh0ktQdgYcOe64MnDTZX0Bibm47hoDldrAlTSffFxQhylqBBoXxDF+Lr
|
||||
hXIqCz7K0PsK+bYusL9ezJ7PETDnCT7oy95q4GXbKsutbNsm9if4ZE41gs2KnoU2
|
||||
DA7kvMmkKojrMIL4+BqTXA20LLo0iSbgvUTvpSJw4u96BeyzMNnxK2wP5vvTtUo5
|
||||
hACbfU87YjaSKs+q2VXCzfyYGZk1L1xk5GUI0bP+jutf1dDzNttW2/q2Nf5rxx09
|
||||
Gh/GwmOnEk1O7cOZ8VQCsOHirIM39NuSARsY6Y3G5XM4k2W4nxyR/RtdG9bvs/33
|
||||
aGsZ5V5yp7WSs8s9HHwaCPSsUiLKckQ7uA0TTRgbeweMrrLKovG57jsbBBB8pQD4
|
||||
PRd31qgxCdstWXHiWwRyI8vOLWENPXPFqA/rJwwqNdWTogy38aqVXxGYR8PIwjA2
|
||||
OaIwFjwGZcsPNLqw6bgAN8O2UBqZHWiMF8mi7brvioDvAIufZuqa2SqT/At45H83
|
||||
psQ6R4FsxZt6SAK7EsdPo8OYTrY1i4iPZd/eKhnEu2srEZgsKRwY5H1mvDH5fWCc
|
||||
HSFu07sWmlmK6Or65Fsa0IaKLJiQDVVETd6xrI0wkM4AOcbKDrS7aywJ426dopbs
|
||||
+LFdt4N0cdII4gBgJAfLuuA2yrDXRq4P6cgpVMy0R+0dEYE8zzm8zf1a+Ud273LS
|
||||
9+LB+LJKwqbW8nOPBoiekimIKfJYoOA4+C/mAjsYl1sVjjEhXJAs9S9L2UvnUk1P
|
||||
sZi4UKHI6eAIEl7VM1sQ4GbdZ0px2dF2Ax7pGkhD+DLpYyYkCprharKZdmuUNLUd
|
||||
NhXxi/HSEiE+Uy+o8RIzmH7LuROl/ZgnfHjJEiBLt2qPvwrwYd4c3XuXWs4YsWfV
|
||||
JTt8Mx2ihgVcdGy9//shCSmgJwR1oWrhgC10AEL2fKeRnYUal1i+IxFPp7nb8uwx
|
||||
UADgR0cY4A3qR/JP489QFIcxBTVs65De+Bq3ecnujk6yeGpD9iptonq4Y8uNZMc1
|
||||
kOE7GiFGwR4EufT5SEMh+tUkjth2r+842vmZZuxrVQaohDiATmIJA07W51zKH+nQ
|
||||
uw4qVKnAhPaDLCLc7YMIH9JcmkeQX0nf8/S2O2WYDH8glVDi5hfW08tCmV647vRY
|
||||
nTIywUTO0lFpz7M+VyMNaJ6yXU6biBV5hLAI8C5ldr/SWI789W2+ebBaJ9gfK+PT
|
||||
trohFSK37GcoSH4V6qSLJHCBASEsiddqHIHMLJZRYD+B6J3tLhjVUM43u+MEGbFT
|
||||
d33ZDke/WzLTExWkaOv36e67gDBmgDuj9yroq3wGfwIDAQABMA0GCSqGSIb3DQEB
|
||||
BAUAA4IEAQCc9RBhRbuWlmRZPZkqIdi5/+enyjoMmOa6ryJPxFSP8D2jrlHgQsk1
|
||||
+GsJmPFT3rwWfoGAQu/aeSX4sp8OhKVJtqNA6MJrGYnZIMolgYa1wZPbkjJsdEfi
|
||||
UsZdIB0n2+KA0xwEdGPdkGCfNPBtOg557DkcyEvsIZ9ELp4Pp2XzWRhyFGasJZc4
|
||||
YwgD/3K2rpOPZoMkBKeKqV19j41OfLKGBVyuaqzitbu9+KT4RU1ibr2a+UuFCwdT
|
||||
oqyN7bfWXjcjXOMkxCsOmLfKmqQxs7TEOVrYPTdYjamDxLy/e5g5FgoCxGY8iil0
|
||||
+YFLZyH6eEx/Os9DlG/M3O1MeRD9U97CdsphbDVZIDyWw5xeX8qQHJe0KSprAgiG
|
||||
TLhTZHeyrKujQCQS1oFFmNy4gSqXt0j1/6/9T80j6HeyjiiYEaEQK9YLTAjRoA7W
|
||||
VN8wtHI5F3RlNOVQEJks/bjdlpLL3VhaWtfewGh/mXRGcow84cgcsejMexmhreHm
|
||||
JfTUl9+X1IFFxGq2/606A9ROQ7kN/s4rXu7/TiMODXI/kZijoWd2SCc7Z0YWoNo7
|
||||
IRKkmZtrsflJbObEuK2Jk59uqzSxyQOBId8qtbPo8qJJyHGV5GCp34g4x67BxJBo
|
||||
h1iyVMamBAS5Ip1ejghuROrB8Hit8NhAZApXju62btJeXLX+mQayXb/wC/IXNJJD
|
||||
83tXiLfZgs6GzLAq7+KW/64sZSvj87CPiNtxkvjchAvyr+fhbBXCrf4rlOjJE6SH
|
||||
Je2/Jon7uqijncARGLBeYUT0Aa6k1slpXuSKxDNt7EIkP21kDZ5/OJ0Y1u587KVB
|
||||
dEhuDgNf2/8ij7gAQBwBoZMe1DrwddrxgLLBlyHpAZetNYFZNT+Cs/OlpqI0Jm59
|
||||
kK9pX0BY4AGOd23XM3K/uLawdmf67kkftim7aVaqXFHPiWsJVtlzmidKvNSmbmZe
|
||||
dOmMXp6PBoqcdusFVUS7vjd3KAes5wUX/CaTyOOPRu0LMSnpwEnaL76IC9x4Jd6d
|
||||
7QqY/OFTjpPH8nP57LwouiT6MgSUCWGaOkPuBJ9w9sENSbbINpgJJ42iAe2kE+R7
|
||||
qEIvf/2ETCTseeQUqm2nWiSPLkNagEh6kojmEoKrGyrv3YjrSXSOY1a70tDVy43+
|
||||
ueQDQzNZm3Q7inpke2ZKvWyY0LQmLzP2te+tnNBcdLyKJx7emPRTuMUlEdK7cLbt
|
||||
V3Sy9IKtyAXqqd66fPFj4NhJygyncj8M6CSqhG5L0GhDbkA8UJ8yK/gfKm3h5xe2
|
||||
utULK5VMtAhQt6cVahO59A9t/OI17y45bmlIgdlEQISzVFe9ZbIUJW44zBfPx74k
|
||||
/w8pMRr8gEuRqpL2WdJiKGG6lhMHLVFo
|
||||
-----END CERTIFICATE-----
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue