mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 03:17:20 +02:00
BUG#55415 wait_for_update_bin_log enters a condition but does not leave
In sql/log.c, member function wait_for_update_bin_log, a condition is entered with THD::enter_cond but is not exited. This might leave dangling references to the mutex/condition in the per-thread information area. To fix the problem, we call exit_cond to properly remove references to the mutex, LOCK_log.
This commit is contained in:
parent
75fd19ad0d
commit
e297990d5b
2 changed files with 9 additions and 6 deletions
|
|
@ -5284,11 +5284,10 @@ int MYSQL_BIN_LOG::wait_for_update_bin_log(THD* thd,
|
|||
const struct timespec *timeout)
|
||||
{
|
||||
int ret= 0;
|
||||
const char* old_msg = thd->proc_info;
|
||||
DBUG_ENTER("wait_for_update_bin_log");
|
||||
old_msg= thd->enter_cond(&update_cond, &LOCK_log,
|
||||
"Master has sent all binlog to slave; "
|
||||
"waiting for binlog to be updated");
|
||||
thd->enter_cond(&update_cond, &LOCK_log,
|
||||
"Master has sent all binlog to slave; "
|
||||
"waiting for binlog to be updated");
|
||||
if (!timeout)
|
||||
mysql_cond_wait(&update_cond, &LOCK_log);
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue