Abort infinite JS loops on quit

This commit is contained in:
Zach Pomerantz 2016-05-04 12:02:08 -07:00
parent 284feaf5d4
commit 56ec0e5db0

View file

@ -216,6 +216,7 @@ void ScriptEngine::waitTillDoneRunning() {
if (elapsedUsecs > MAX_SCRIPT_EVALUATION_TIME) {
qCDebug(scriptengine) <<
"Script " << scriptName << " has been running too long [" << elapsedUsecs << " usecs] quitting.";
abortEvaluation(); // to allow the thread to quit
workerThread->quit();
break;
}