Commit 662f7a12 authored by kouhei@chromium.org's avatar kouhei@chromium.org

Add a comment about calling clearScriptObjects before clearForNavigation.

This is a follow up CL to r178818, adding a comment why the order is important.

BUG=364377
NOTRY=true

Review URL: https://codereview.chromium.org/460053002

git-svn-id: svn://svn.chromium.org/blink/trunk@180024 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 7b0f057c
......@@ -421,6 +421,9 @@ void ScriptController::clearWindowShell()
double start = currentTime();
// V8 binding expects ScriptController::clearWindowShell only be called
// when a frame is loading a new page. This creates a new context for the new page.
// The V8 context must be available for |clearScriptObjects()|.
// The below call must be before |clearForNavigation()| which disposes the V8 context.
clearScriptObjects();
m_windowShell->clearForNavigation();
for (IsolatedWorldMap::iterator iter = m_isolatedWorlds.begin(); iter != m_isolatedWorlds.end(); ++iter)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment