diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-31 17:22:08 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-10-31 17:22:08 +0000 |
commit | f83a293733e94fa6e0cc8e3720372a1bea58f4ee (patch) | |
tree | 32b209df44c33a276b30e83f61dbd9073d32fcd3 /chrome | |
parent | 45003a76537ada4d727e0b33f28961a72938c9e7 (diff) | |
download | chromium_src-f83a293733e94fa6e0cc8e3720372a1bea58f4ee.zip chromium_src-f83a293733e94fa6e0cc8e3720372a1bea58f4ee.tar.gz chromium_src-f83a293733e94fa6e0cc8e3720372a1bea58f4ee.tar.bz2 |
Attempt to fix dist crashes or at least make them crash with more understandable stack traces. Destroy the dragged representation immediately, not after returning to the message loop.
Review URL: http://codereview.chromium.org/8926
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4295 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/views/tabs/dragged_tab_controller.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/chrome/browser/views/tabs/dragged_tab_controller.cc b/chrome/browser/views/tabs/dragged_tab_controller.cc index 455c703..4da9dba 100644 --- a/chrome/browser/views/tabs/dragged_tab_controller.cc +++ b/chrome/browser/views/tabs/dragged_tab_controller.cc @@ -521,8 +521,11 @@ void DraggedTabController::Detach() { if (!photobooth_.get()) photobooth_.reset(new HWNDPhotobooth(dragged_contents_->GetContainerHWND())); - // Update the View. - view_->Detach(photobooth_.get()); + // Update the View. This NULL check is necessary apparently in some + // conditions during automation where the view_ is destroyed inside a + // function call preceding this point but after it is created. + if (view_.get()) + view_->Detach(photobooth_.get()); // We need to be the delegate so we receive messages about stuff, // otherwise our dragged_contents() may be replaced and subsequently |