mirror of
https://github.com/MariaDB/server.git
synced 2025-08-07 00:04:31 +03:00
Merge 10.5 into 10.6
This commit is contained in:
@@ -1835,15 +1835,20 @@ static void cleanup()
|
||||
my_free_open_file_info();
|
||||
load_processor.destroy();
|
||||
mysql_server_end();
|
||||
if (opt_flashback)
|
||||
{
|
||||
delete_dynamic(&binlog_events);
|
||||
delete_dynamic(&events_in_stmt);
|
||||
}
|
||||
DBUG_VOID_RETURN;
|
||||
}
|
||||
|
||||
|
||||
static void die()
|
||||
static void die(int err)
|
||||
{
|
||||
cleanup();
|
||||
my_end(MY_DONT_FREE_DBUG);
|
||||
exit(1);
|
||||
exit(err);
|
||||
}
|
||||
|
||||
|
||||
@@ -1880,7 +1885,7 @@ static my_time_t convert_str_to_timestamp(const char* str)
|
||||
l_time.time_type != MYSQL_TIMESTAMP_DATETIME || status.warnings)
|
||||
{
|
||||
error("Incorrect date and time argument: %s", str);
|
||||
die();
|
||||
die(1);
|
||||
}
|
||||
/*
|
||||
Note that Feb 30th, Apr 31st cause no error messages and are mapped to
|
||||
@@ -1947,7 +1952,7 @@ get_one_option(const struct my_option *opt, const char *argument, const char *fi
|
||||
opt->name)) <= 0)
|
||||
{
|
||||
sf_leaking_memory= 1; /* no memory leak reports here */
|
||||
die();
|
||||
die(1);
|
||||
}
|
||||
|
||||
/* Specification of protocol via CLI trumps implicit overrides */
|
||||
@@ -1976,7 +1981,7 @@ get_one_option(const struct my_option *opt, const char *argument, const char *fi
|
||||
opt->name)) <= 0)
|
||||
{
|
||||
sf_leaking_memory= 1; /* no memory leak reports here */
|
||||
die();
|
||||
die(1);
|
||||
}
|
||||
opt_base64_output_mode= (enum_base64_output_mode)(val - 1);
|
||||
break;
|
||||
@@ -2093,7 +2098,7 @@ static int parse_args(int *argc, char*** argv)
|
||||
|
||||
if ((ho_error=handle_options(argc, argv, my_options, get_one_option)))
|
||||
{
|
||||
die();
|
||||
die(ho_error);
|
||||
}
|
||||
if (debug_info_flag)
|
||||
my_end_arg= MY_CHECK_ERROR | MY_GIVE_INFO;
|
||||
@@ -3060,6 +3065,12 @@ int main(int argc, char** argv)
|
||||
|
||||
my_set_max_open_files(open_files_limit);
|
||||
|
||||
if (opt_flashback && opt_raw_mode)
|
||||
{
|
||||
error("The --raw mode is not allowed with --flashback mode");
|
||||
die(1);
|
||||
}
|
||||
|
||||
if (opt_flashback)
|
||||
{
|
||||
my_init_dynamic_array(PSI_NOT_INSTRUMENTED, &binlog_events,
|
||||
@@ -3075,7 +3086,7 @@ int main(int argc, char** argv)
|
||||
if (!remote_opt)
|
||||
{
|
||||
error("The --raw mode only works with --read-from-remote-server");
|
||||
die();
|
||||
die(1);
|
||||
}
|
||||
if (one_database)
|
||||
warning("The --database option is ignored in raw mode");
|
||||
@@ -3097,7 +3108,7 @@ int main(int argc, char** argv)
|
||||
O_WRONLY | O_BINARY, MYF(MY_WME))))
|
||||
{
|
||||
error("Could not create log file '%s'", result_file_name);
|
||||
die();
|
||||
die(1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -3186,7 +3197,7 @@ int main(int argc, char** argv)
|
||||
/* Set delimiter back to semicolon */
|
||||
if (retval != ERROR_STOP)
|
||||
{
|
||||
if (!stop_event_string.is_empty())
|
||||
if (!stop_event_string.is_empty() && result_file)
|
||||
fprintf(result_file, "%s", stop_event_string.ptr());
|
||||
if (!opt_raw_mode && opt_flashback)
|
||||
fprintf(result_file, "DELIMITER ;\n");
|
||||
|
Reference in New Issue
Block a user