Fix: ScriptFrame's 'Self' attribute gets corrupted when an expressions throws an exception

fixes #9795
This commit is contained in:
Gunnar Beutner 2015-07-30 20:22:02 +02:00
parent 9d098482dd
commit 5bd46c2b38
1 changed files with 2 additions and 1 deletions

View File

@ -460,7 +460,8 @@ ExpressionResult DictExpression::DoEvaluate(ScriptFrame& frame, DebugHint *dhint
result = element.GetValue(); result = element.GetValue();
} }
} catch (...) { } catch (...) {
std::swap(self, frame.Self); if (!m_Inline)
std::swap(self, frame.Self);
throw; throw;
} }