mirror of https://github.com/WerWolv/ImHex.git
fix: Evaluator not exiting evaluating state correctly on error
This commit is contained in:
parent
a44de63e24
commit
9055105627
|
@ -1 +1 @@
|
||||||
Subproject commit 6880b7bb8e871f47ef4536dd59f35175aa2da4eb
|
Subproject commit b962a3db79b6f18c454a758cc72dd128ce1a4e28
|
|
@ -854,16 +854,18 @@ namespace hex::plugin::builtin {
|
||||||
return this->m_dangerousFunctionsAllowed == DangerousFunctionPerms::Allow;
|
return this->m_dangerousFunctionsAllowed == DangerousFunctionPerms::Allow;
|
||||||
});
|
});
|
||||||
|
|
||||||
this->m_lastEvaluationResult = runtime->executeString(code, envVars, inVariables);
|
ON_SCOPE_EXIT {
|
||||||
if (!this->m_lastEvaluationResult) {
|
|
||||||
this->m_lastEvaluationError = runtime->getError();
|
|
||||||
}
|
|
||||||
|
|
||||||
this->m_lastEvaluationLog = runtime->getConsoleLog();
|
this->m_lastEvaluationLog = runtime->getConsoleLog();
|
||||||
this->m_lastEvaluationOutVars = runtime->getOutVariables();
|
this->m_lastEvaluationOutVars = runtime->getOutVariables();
|
||||||
this->m_runningEvaluators--;
|
this->m_runningEvaluators--;
|
||||||
|
|
||||||
this->m_lastEvaluationProcessed = false;
|
this->m_lastEvaluationProcessed = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
this->m_lastEvaluationResult = runtime->executeString(code, envVars, inVariables);
|
||||||
|
if (!this->m_lastEvaluationResult) {
|
||||||
|
this->m_lastEvaluationError = runtime->getError();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue