Merge pull request #28881 from azat/mysql-sync-thread-joinable

Join MaterializedMySQLSyncThread only if it is joinable
This commit is contained in:
Maksim Kita 2021-09-11 11:35:43 +03:00 committed by GitHub
commit aef6112af4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -233,7 +233,8 @@ void MaterializedMySQLSyncThread::stopSynchronization()
if (!sync_quit && background_thread_pool)
{
sync_quit = true;
background_thread_pool->join();
if (background_thread_pool->joinable())
background_thread_pool->join();
client.disconnect();
}
}