summaryrefslogtreecommitdiffstats
path: root/chrome/renderer/extensions
diff options
context:
space:
mode:
authormpcomplete@chromium.org <mpcomplete@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-18 00:46:03 +0000
committermpcomplete@chromium.org <mpcomplete@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-18 00:46:03 +0000
commitabfef857b0e4f5cad1da9ce0f751283292a4aab6 (patch)
tree9237aede6cb27dac8de510242bf86bbe352faf61 /chrome/renderer/extensions
parent72e4168fc1a899da763adef6100f9f842bb6d70d (diff)
downloadchromium_src-abfef857b0e4f5cad1da9ce0f751283292a4aab6.zip
chromium_src-abfef857b0e4f5cad1da9ce0f751283292a4aab6.tar.gz
chromium_src-abfef857b0e4f5cad1da9ce0f751283292a4aab6.tar.bz2
Dispose of V8 contexts when an extension request gets a response.
This fixes a memory leak of any V8 context that used an extension API. This mostly affected popups and tab contents, since they are the extension views that close. BUG=30194 Review URL: http://codereview.chromium.org/504053 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34912 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/extensions')
-rw-r--r--chrome/renderer/extensions/extension_process_bindings.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/chrome/renderer/extensions/extension_process_bindings.cc b/chrome/renderer/extensions/extension_process_bindings.cc
index 540469f..c1009c3e 100644
--- a/chrome/renderer/extensions/extension_process_bindings.cc
+++ b/chrome/renderer/extensions/extension_process_bindings.cc
@@ -637,6 +637,8 @@ void ExtensionProcessBindings::HandleResponse(int request_id, bool success,
}
#endif
+ request->second->context.Dispose();
+ request->second->context.Clear();
pending_requests.erase(request);
}