Fix destructor when `start()` hasn't been called

This commit is contained in:
Jason Rhinelander 2020-03-03 17:28:53 -04:00
parent 2207198574
commit ea5ff7790d
1 changed files with 3 additions and 0 deletions

View File

@ -1747,6 +1747,9 @@ void LokiMQ::process_zap_requests() {
}
LokiMQ::~LokiMQ() {
if (!proxy_thread.joinable())
return;
LMQ_LOG(info, "LokiMQ shutting down proxy thread");
detail::send_control(get_control_socket(), "QUIT");
proxy_thread.join();