Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3389)

Unified Diff: chrome/browser/ui/webui/sync_setup_handler.cc

Issue 8588013: Fix crash in SyncSetupWizard::IsVisible() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/sync_setup_handler.cc
diff --git a/chrome/browser/ui/webui/sync_setup_handler.cc b/chrome/browser/ui/webui/sync_setup_handler.cc
index 914f823f745edb3a76a69797f61db8f241a93202..c1bad70264aed3562db447af5e1130fb5bf4e3f5 100644
--- a/chrome/browser/ui/webui/sync_setup_handler.cc
+++ b/chrome/browser/ui/webui/sync_setup_handler.cc
@@ -703,7 +703,9 @@ void SyncSetupHandler::OpenSyncSetup() {
bool SyncSetupHandler::FocusExistingWizard() {
Profile* profile = Profile::FromWebUI(web_ui_);
ProfileSyncService* service = profile->GetProfileSyncService();
- DCHECK(service);
+ if (!service)
James Hawkins 2011/11/17 02:23:53 When is |service| NULL?
binji 2011/11/17 21:02:09 When using an incognito profile.
+ return false;
+
// If the wizard is already visible, focus it.
if (service->get_wizard().IsVisible()) {
service->get_wizard().Focus();
« chrome/browser/ui/browser_navigator.cc ('K') | « chrome/browser/ui/browser_navigator.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698