Showing the changes to libraries/script-engine/src/ScriptEngine.cpp (1 of 1 file). Show all
Unified · Split
| @@ -419,7 +419,7 @@ void ScriptEngine::waitTillDoneRunning() { · 418 unmodified lines | ||
| 419 | 419 | // Wait for the scripting thread to stop running, as |
| 420 | 420 | // flooding it with aborts/exceptions will persist it longer |
| 421 | 421 | static const auto MAX_SCRIPT_QUITTING_TIME = 0.5 * MSECS_PER_SECOND; |
| 422 | − if (workerThread->wait(MAX_SCRIPT_QUITTING_TIME)) { | |
| 422 | + if (!workerThread->wait(MAX_SCRIPT_QUITTING_TIME)) { | |
| 423 | 423 | workerThread->terminate(); |
| 424 | 424 | } |
| 425 | 425 | } |