Chromium Code Reviews| Index: third_party/WebKit/Source/core/frame/DOMTimer.cpp |
| diff --git a/third_party/WebKit/Source/core/frame/DOMTimer.cpp b/third_party/WebKit/Source/core/frame/DOMTimer.cpp |
| index e38ac74e6489aa12c3e4eb579ca5f997bd5976ab..fbd084519f8036a2c1367078a115dadf1154d0d8 100644 |
| --- a/third_party/WebKit/Source/core/frame/DOMTimer.cpp |
| +++ b/third_party/WebKit/Source/core/frame/DOMTimer.cpp |
| @@ -157,8 +157,15 @@ void DOMTimer::fired() { |
| augmentRepeatInterval(minimumInterval - repeatInterval()); |
| } |
| + // Get ExecutionContext early as it might be cleared during |
| + // action->execute(). |
| + ExecutionContext* executionContext = getExecutionContext(); |
|
jochen (gone - plz use gerrit)
2017/02/15 15:26:48
sorry for not catching this earlier, but |context|
Dan Elphick
2017/02/15 16:24:52
Done.
|
| + |
| // No access to member variables after this point, it can delete the timer. |
| m_action->execute(context); |
| + |
| + executionContext->timers()->setTimerNestingLevel(0); |
| + |
| return; |
| } |