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

Side by Side Diff: sync/test/test_directory_backing_store.cc

Issue 10821121: sync: Attempt to recover from directory corruption (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix other win compile warning Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « sync/syncable/on_disk_directory_backing_store.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "sync/test/test_directory_backing_store.h" 5 #include "sync/test/test_directory_backing_store.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 9
10 namespace syncer { 10 namespace syncer {
(...skipping 17 matching lines...) Expand all
28 28
29 if (!InitializeTables()) 29 if (!InitializeTables())
30 return FAILED_OPEN_DATABASE; 30 return FAILED_OPEN_DATABASE;
31 31
32 if (!DropDeletedEntries()) 32 if (!DropDeletedEntries())
33 return FAILED_DATABASE_CORRUPT; 33 return FAILED_DATABASE_CORRUPT;
34 if (!LoadEntries(entry_bucket)) 34 if (!LoadEntries(entry_bucket))
35 return FAILED_DATABASE_CORRUPT; 35 return FAILED_DATABASE_CORRUPT;
36 if (!LoadInfo(kernel_load_info)) 36 if (!LoadInfo(kernel_load_info))
37 return FAILED_DATABASE_CORRUPT; 37 return FAILED_DATABASE_CORRUPT;
38 if (!VerifyReferenceIntegrity(*entry_bucket))
39 return FAILED_DATABASE_CORRUPT;
38 40
39 return OPENED; 41 return OPENED;
40 } 42 }
41 43
42 } // namespace syncable 44 } // namespace syncable
43 } // namespace syncer 45 } // namespace syncer
OLDNEW
« no previous file with comments | « sync/syncable/on_disk_directory_backing_store.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698