summaryrefslogtreecommitdiffstats
path: root/chrome/browser/sync
diff options
context:
space:
mode:
authorrlarocque@chromium.org <rlarocque@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-05 20:36:32 +0000
committerrlarocque@chromium.org <rlarocque@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-01-05 20:36:32 +0000
commite101217fb8adc0502d8b53922286d1ebf45b6a5e (patch)
tree883a1da7fe253a8a8fd8b88bffcee469bd718fce /chrome/browser/sync
parent853cd0a3ca9fced3ed1ff6add9c9947d048d1443 (diff)
downloadchromium_src-e101217fb8adc0502d8b53922286d1ebf45b6a5e.zip
chromium_src-e101217fb8adc0502d8b53922286d1ebf45b6a5e.tar.gz
chromium_src-e101217fb8adc0502d8b53922286d1ebf45b6a5e.tar.bz2
Fix var hiding bug in sync's UIModelWorker
There's an extra declaration of error_info that hides the original declaration. We use the variable in the inner scope. When the scope ends, return the still-uninitialized variable from the outer scope. This commit fixes that bug by removing the declaration in the inner scope. BUG=105994 TEST= Review URL: http://codereview.chromium.org/9087020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@116538 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/sync')
-rw-r--r--chrome/browser/sync/glue/ui_model_worker.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/chrome/browser/sync/glue/ui_model_worker.cc b/chrome/browser/sync/glue/ui_model_worker.cc
index c7ca1c5..754f625 100644
--- a/chrome/browser/sync/glue/ui_model_worker.cc
+++ b/chrome/browser/sync/glue/ui_model_worker.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -68,7 +68,6 @@ UnrecoverableErrorInfo UIModelWorker::DoWorkAndWaitUntilDone(
// The task is owned by the message loop as per usual.
base::AutoLock lock(lock_);
DCHECK(pending_work_.is_null());
- UnrecoverableErrorInfo error_info;
pending_work_ = base::Bind(&CallDoWorkAndSignalCallback, work, &work_done,
base::Unretained(this), &error_info);
if (!BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, pending_work_)) {