From f9f0a4ea2d282023c3d25b25712be1d945b918fa Mon Sep 17 00:00:00 2001 From: howard-stearns Date: Thu, 26 Jan 2017 14:05:16 -0800 Subject: [PATCH] fix startup-failure case --- assignment-client/src/entities/EntityServer.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/assignment-client/src/entities/EntityServer.cpp b/assignment-client/src/entities/EntityServer.cpp index ff93dbae09..724571c111 100644 --- a/assignment-client/src/entities/EntityServer.cpp +++ b/assignment-client/src/entities/EntityServer.cpp @@ -367,9 +367,9 @@ void EntityServer::scriptRequestFinished() { if (_scriptRequestLoop.isRunning()) { _scriptRequestLoop.quit(); } + return; } } - return; } else if (scriptRequest) { qCritical() << "Failed to download script at" << urlString; // See HTTPResourceRequest::onRequestFinished for interpretation of codes. For example, a 404 is code 6 and 403 is 3. A timeout is 2. Go figure. @@ -380,6 +380,9 @@ void EntityServer::scriptRequestFinished() { // Hard stop of the assignment client on failure. We don't want anyone to think they have a filter in place when they don't. // Alas, only indications will be the above logging with assignment client restarting repeatedly, and clients will not see any entities. stop(); + if (_scriptRequestLoop.isRunning()) { + _scriptRequestLoop.quit(); + } } void EntityServer::nodeAdded(SharedNodePointer node) {