summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync
diff options
context:
space:
mode:
authornick@chromium.org <nick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-21 21:29:13 +0000
committernick@chromium.org <nick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-21 21:29:13 +0000
commit7106ae5055a009e1ca53f0fc5ee6bb6b0c925c9f (patch)
treeee46efbabfffbe4f0f4b8fad7c07700728c30a7b /chrome/browser/sync
parent595fbb4e449423faa19cbf9533d980bd2b100479 (diff)
downloadchromium_src-7106ae5055a009e1ca53f0fc5ee6bb6b0c925c9f.zip
chromium_src-7106ae5055a009e1ca53f0fc5ee6bb6b0c925c9f.tar.gz
chromium_src-7106ae5055a009e1ca53f0fc5ee6bb6b0c925c9f.tar.bz2
Fix an observed shutdown crash after downgrading to an older Chrome release.
Review URL: http://codereview.chromium.org/548105 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36784 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync')
-rwxr-xr-xchrome/browser/sync/engine/syncapi.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/chrome/browser/sync/engine/syncapi.cc b/chrome/browser/sync/engine/syncapi.cc
index caa92e0..0c8d9bc 100755
--- a/chrome/browser/sync/engine/syncapi.cc
+++ b/chrome/browser/sync/engine/syncapi.cc
@@ -1336,8 +1336,10 @@ void SyncManager::SyncInternal::Shutdown() {
// it terminates gracefully before we shutdown and close other components.
// Otherwise the attempt can complete after we've closed the directory, for
// example, and cause initialization to continue, which is bad.
- auth_watcher_->Shutdown();
- auth_watcher_ = NULL;
+ if (auth_watcher_) {
+ auth_watcher_->Shutdown();
+ auth_watcher_ = NULL;
+ }
if (syncer_thread()) {
if (!syncer_thread()->Stop(kThreadExitTimeoutMsec))