Index: chrome/browser/webdata/autofill_profile_syncable_service.h |
diff --git a/chrome/browser/webdata/autofill_profile_syncable_service.h b/chrome/browser/webdata/autofill_profile_syncable_service.h |
index 77ef314bbc5ee5bf1191940d2a95623b838f4244..044a63275f2e54562cce6edc6d67567dabd44200 100644 |
--- a/chrome/browser/webdata/autofill_profile_syncable_service.h |
+++ b/chrome/browser/webdata/autofill_profile_syncable_service.h |
@@ -11,6 +11,7 @@ |
#include "base/basictypes.h" |
#include "base/memory/scoped_vector.h" |
+#include "base/memory/weak_ptr.h" |
#include "base/synchronization/lock.h" |
#include "base/threading/non_thread_safe.h" |
#include "chrome/browser/sync/api/sync_change.h" |
@@ -41,6 +42,7 @@ class UnrecoverableErrorHandler; |
// ProcessSyncChanges() and for each local change Observe() is called. |
class AutofillProfileSyncableService |
: public SyncableService, |
+ public base::SupportsWeakPtr<AutofillProfileSyncableService>, |
public NotificationObserver, |
public base::NonThreadSafe { |
public: |
@@ -130,7 +132,7 @@ class AutofillProfileSyncableService |
// For unit-tests. |
AutofillProfileSyncableService(); |
void set_sync_processor(SyncChangeProcessor* sync_processor) { |
- sync_processor_ = sync_processor; |
+ sync_processor_.reset(sync_processor); |
} |
WebDataService* web_data_service_; // WEAK |
@@ -141,7 +143,7 @@ class AutofillProfileSyncableService |
ScopedVector<AutofillProfile> profiles_; |
GUIDToProfileMap profiles_map_; |
- SyncChangeProcessor* sync_processor_; |
+ scoped_ptr<SyncChangeProcessor> sync_processor_; |
DISALLOW_COPY_AND_ASSIGN(AutofillProfileSyncableService); |
}; |