summaryrefslogtreecommitdiffstats
path: root/chrome/common/common.scons
diff options
context:
space:
mode:
authorjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-22 22:24:14 +0000
committerjcampan@chromium.org <jcampan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-12-22 22:24:14 +0000
commitbc2274f796a84892829b4dbdb7f57dde34ed6f21 (patch)
tree2c44a73ac1c6fba22e2ecd31ea9e22938f875eaa /chrome/common/common.scons
parenta5263cb1bb99193f1edf59fa65fe4d6e5cd8e702 (diff)
downloadchromium_src-bc2274f796a84892829b4dbdb7f57dde34ed6f21.zip
chromium_src-bc2274f796a84892829b4dbdb7f57dde34ed6f21.tar.gz
chromium_src-bc2274f796a84892829b4dbdb7f57dde34ed6f21.tar.bz2
My Friday fix for some stack trashing introduced some heap trashing!
The tests create PageInterstitial objects which are self-owned (they delete themselves when hidden). The tests test whether the PageInterstitial instance has been deleted by passing a local variable boolean to its constructor that the InterstitialPage sets to true when deleted. In the stack trashing case, in one of the test the interstitial was deleted from the TearDown() method, so outside of the scope of the test. The interstitial was still accessing the local variable from the test scope, trashing the stack. My previous fix introduced a state guard class allocated on the stack that would notify the InterstitialPage when deleted so it would clear any reference to the local vars, which fixed the stack trashing. But this created a new problem: when the interstitial is deleted in the scope of the unit tests, the state guard object still holds a reference to the now deleted interstitial and calls a method on it when itself deleted. This CL ensures the state guard class does not access any deleted interstitial. BUG=5789 Review URL: http://codereview.chromium.org/16423 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7384 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/common.scons')
0 files changed, 0 insertions, 0 deletions