mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Manual merge
This commit is contained in:
27
sql/log.cc
27
sql/log.cc
@ -3070,6 +3070,7 @@ int MYSQL_BIN_LOG::purge_logs(const char *to_log,
|
|||||||
int ret = 0;
|
int ret = 0;
|
||||||
bool exit_loop= 0;
|
bool exit_loop= 0;
|
||||||
LOG_INFO log_info;
|
LOG_INFO log_info;
|
||||||
|
THD *thd =current_thd;
|
||||||
DBUG_ENTER("purge_logs");
|
DBUG_ENTER("purge_logs");
|
||||||
DBUG_PRINT("info",("to_log= %s",to_log));
|
DBUG_PRINT("info",("to_log= %s",to_log));
|
||||||
|
|
||||||
@ -3140,18 +3141,30 @@ int MYSQL_BIN_LOG::purge_logs(const char *to_log,
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
push_warning_printf(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR,
|
if (thd)
|
||||||
ER_BINLOG_PURGE_FATAL_ERR,
|
{
|
||||||
"a problem with deleting %s; "
|
push_warning_printf(thd, MYSQL_ERROR::WARN_LEVEL_ERROR,
|
||||||
"consider examining correspondence "
|
ER_BINLOG_PURGE_FATAL_ERR,
|
||||||
"of your binlog index file "
|
"a problem with deleting %s; "
|
||||||
"to the actual binlog files",
|
"consider examining correspondence "
|
||||||
log_info.log_file_name);
|
"of your binlog index file "
|
||||||
|
"to the actual binlog files",
|
||||||
|
log_info.log_file_name);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sql_print_information("Failed to delete file '%s'; "
|
||||||
|
"consider examining correspondence "
|
||||||
|
"of your binlog index file "
|
||||||
|
"to the actual binlog files",
|
||||||
|
log_info.log_file_name);
|
||||||
|
}
|
||||||
if (my_errno == EMFILE)
|
if (my_errno == EMFILE)
|
||||||
{
|
{
|
||||||
DBUG_PRINT("info",
|
DBUG_PRINT("info",
|
||||||
("my_errno: %d, set ret = LOG_INFO_EMFILE", my_errno));
|
("my_errno: %d, set ret = LOG_INFO_EMFILE", my_errno));
|
||||||
error= LOG_INFO_EMFILE;
|
error= LOG_INFO_EMFILE;
|
||||||
|
goto err;
|
||||||
}
|
}
|
||||||
error= LOG_INFO_FATAL;
|
error= LOG_INFO_FATAL;
|
||||||
goto err;
|
goto err;
|
||||||
|
Reference in New Issue
Block a user