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

Unified Diff: chrome/browser/sync/glue/session_model_associator.cc

Issue 7497014: Revert 94128 - [Sync] Refactor sync datatype error handling. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 5 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
Index: chrome/browser/sync/glue/session_model_associator.cc
===================================================================
--- chrome/browser/sync/glue/session_model_associator.cc (revision 94142)
+++ chrome/browser/sync/glue/session_model_associator.cc (working copy)
@@ -14,7 +14,6 @@
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/sessions/restore_tab_helper.h"
#include "chrome/browser/sessions/session_service_factory.h"
-#include "chrome/browser/sync/api/sync_error.h"
#include "chrome/browser/sync/glue/synced_window_delegate.h"
#include "chrome/browser/sync/profile_sync_service.h"
#include "chrome/browser/sync/syncable/syncable.h"
@@ -408,7 +407,7 @@
// TODO(zea): we will need this once we support deleting foreign sessions.
}
-bool SessionModelAssociator::AssociateModels(SyncError* error) {
+bool SessionModelAssociator::AssociateModels() {
DCHECK(CalledOnValidThread());
// Ensure that we disassociated properly, otherwise memory might leak.
@@ -424,7 +423,7 @@
sync_api::ReadNode root(&trans);
if (!root.InitByTagLookup(kSessionsTag)) {
- error->Reset(FROM_HERE, kNoSessionsFolderError, model_type());
+ LOG(ERROR) << kNoSessionsFolderError;
return false;
}
@@ -439,9 +438,7 @@
sync_api::WriteNode write_node(&trans);
if (!write_node.InitUniqueByCreation(syncable::SESSIONS, root,
current_machine_tag_)) {
- error->Reset(FROM_HERE,
- "Failed to create sessions header sync node.",
- model_type());
+ LOG(ERROR) << "Failed to create sessions header sync node.";
return false;
}
write_node.SetTitle(UTF8ToWide(current_machine_tag_));
@@ -457,7 +454,7 @@
return true;
}
-bool SessionModelAssociator::DisassociateModels(SyncError* error) {
+bool SessionModelAssociator::DisassociateModels() {
DCHECK(CalledOnValidThread());
synced_session_tracker_.clear();
tab_map_.clear();
« no previous file with comments | « chrome/browser/sync/glue/session_model_associator.h ('k') | chrome/browser/sync/glue/syncable_service_adapter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698