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

Unified Diff: chrome/browser/sync/sync_ui_util.cc

Issue 7054017: [Sync] Avoid triggering NOTREACHED in PSS::GetLastSessionSnapshot() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/sync/sync_ui_util.cc
diff --git a/chrome/browser/sync/sync_ui_util.cc b/chrome/browser/sync/sync_ui_util.cc
index e6cd8508e427252b6abb3e7e59b2904cf8f96123..0c95bd6c28c0d964145c31384754beba38d7c841 100644
--- a/chrome/browser/sync/sync_ui_util.cc
+++ b/chrome/browser/sync/sync_ui_util.cc
@@ -427,9 +427,10 @@ void ConstructAboutInformation(ProfileSyncService* service,
full_status.useful_sync_cycles);
const browser_sync::sessions::SyncSessionSnapshot* snapshot =
- service->GetLastSessionSnapshot();
+ service->sync_initialized() ?
+ service->GetLastSessionSnapshot() : NULL;
- // |snapshot| could be null if sync is not yet completed.
+ // |snapshot| could be NULL if sync is not yet initialized.
if (snapshot) {
sync_ui_util::AddIntSyncDetail(details, "Download Count (This Session)",
snapshot->syncer_status.num_updates_downloaded_total);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698