Browse Source

MDEV-28976 fixup: A better fix

do_shutdown_server(): After sending SIGKILL, invoke wait_until_dead().
Thanks to Sergei Golubchik for pointing out that the previous fix
does not actually work.
pull/2480/head
Marko Mäkelä 3 years ago
parent
commit
854e8b189e
  1. 3
      client/mysqltest.cc

3
client/mysqltest.cc

@ -5191,9 +5191,10 @@ void do_shutdown_server(struct st_command *command)
if (timeout)
(void) my_kill(pid, SIGABRT);
/* Give server a few seconds to die in all cases */
if (wait_until_dead(pid, timeout < 5 ? 5 : timeout))
if (!timeout || wait_until_dead(pid, timeout < 5 ? 5 : timeout))
{
(void) my_kill(pid, SIGKILL);
wait_until_dead(pid, 5);
}
}
DBUG_VOID_RETURN;

Loading…
Cancel
Save