diff options
author | sky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-01 16:57:13 +0000 |
---|---|---|
committer | sky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-11-01 16:57:13 +0000 |
commit | 7c9d829192359328576965fe8a4a52a5ad6c7da3 (patch) | |
tree | 6f06ef0a1bd4f797ad2c9f2968950b625867136c /chrome/browser/hang_monitor | |
parent | 9d3fcf8bc99dfdfef66b983af69802ddbe76514d (diff) | |
download | chromium_src-7c9d829192359328576965fe8a4a52a5ad6c7da3.zip chromium_src-7c9d829192359328576965fe8a4a52a5ad6c7da3.tar.gz chromium_src-7c9d829192359328576965fe8a4a52a5ad6c7da3.tar.bz2 |
Attempt at fixing leaks from SetProp. Apparently there is a finite
amount of memory reserved for properties and Windows doesn't always
automatically free up the memory if the window is deleted without an
explicit remove. For the time being I've made it easier to track
SetProp leaks, but we may want to move to using something other than
SetProp in the future that isn't as fragile.
I didn't fix a couple of places that were trickier. I'm going to file
separate bugs on them.
BUG=44991
TEST=none
Review URL: http://codereview.chromium.org/4195003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64619 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/hang_monitor')
-rw-r--r-- | chrome/browser/hang_monitor/hung_plugin_action.cc | 1 | ||||
-rw-r--r-- | chrome/browser/hang_monitor/hung_window_detector.cc | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/chrome/browser/hang_monitor/hung_plugin_action.cc b/chrome/browser/hang_monitor/hung_plugin_action.cc index 5fdcfd1..8399464 100644 --- a/chrome/browser/hang_monitor/hung_plugin_action.cc +++ b/chrome/browser/hang_monitor/hung_plugin_action.cc @@ -80,6 +80,7 @@ bool HungPluginAction::OnHungWindowDetected(HWND hung_window, if (child_window_message_timeout) { child_window_message_timeout *= 2; #pragma warning(disable:4312) + // TODO: this leaks. SetProp(hung_window, HungWindowDetector::kHungChildWindowTimeout, reinterpret_cast<HANDLE>(child_window_message_timeout)); #pragma warning(default:4312) diff --git a/chrome/browser/hang_monitor/hung_window_detector.cc b/chrome/browser/hang_monitor/hung_window_detector.cc index 73b84a8..a9bdead 100644 --- a/chrome/browser/hang_monitor/hung_window_detector.cc +++ b/chrome/browser/hang_monitor/hung_window_detector.cc @@ -101,6 +101,7 @@ bool HungWindowDetector::CheckChildWindow(HWND child_window) { HungWindowNotification::ActionOnHungWindow action = HungWindowNotification::HUNG_WINDOW_IGNORE; #pragma warning(disable:4312) + // TODO: this leaks. SetProp(child_window, kHungChildWindowTimeout, reinterpret_cast<HANDLE>(child_window_message_timeout)); #pragma warning(default:4312) |