make sure LNL goes down before domain-server

This commit is contained in:
Stephen Birarda 2015-08-20 10:01:12 -07:00
parent bb15811f6b
commit 74d6e5ba89
3 changed files with 9 additions and 2 deletions

View file

@ -110,6 +110,11 @@ DomainServer::DomainServer(int argc, char* argv[]) :
}
}
DomainServer::~DomainServer() {
// destroy the LimitedNodeList before the DomainServer QCoreApplication is down
DependencyManager::destroy<LimitedNodeList>();
}
void DomainServer::aboutToQuit() {
// clear the log handler so that Qt doesn't call the destructor on LogHandler

View file

@ -38,7 +38,8 @@ class DomainServer : public QCoreApplication, public HTTPSRequestHandler {
Q_OBJECT
public:
DomainServer(int argc, char* argv[]);
~DomainServer();
static int const EXIT_CODE_REBOOT;
bool handleHTTPRequest(HTTPConnection* connection, const QUrl& url, bool skipSubHandler = false);

View file

@ -58,7 +58,8 @@ Connection::~Connection() {
_sendQueue->deleteLater();
_sendQueue.release();
// wait on the send queue thread so we know the send queue is gone
// wait on the send queue thread so we know the send queue is gone
sendQueueThread->quit();
sendQueueThread->wait();
}
}