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

Unified Diff: content/browser/indexed_db/indexed_db_backing_store.h

Issue 237143006: Make iterating over a corrupted IndexedDB fail. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 8 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: content/browser/indexed_db/indexed_db_backing_store.h
diff --git a/content/browser/indexed_db/indexed_db_backing_store.h b/content/browser/indexed_db/indexed_db_backing_store.h
index ed2e39589e0d03eeef89b3cd80e5cf3504c288c0..1dac5480e549d111893a76dcfb313ab75abc8d6f 100644
--- a/content/browser/indexed_db/indexed_db_backing_store.h
+++ b/content/browser/indexed_db/indexed_db_backing_store.h
@@ -97,7 +97,7 @@ class CONTENT_EXPORT IndexedDBBackingStore
// Compact is public for testing.
virtual void Compact();
- virtual std::vector<base::string16> GetDatabaseNames();
+ virtual std::vector<base::string16> GetDatabaseNames(leveldb::Status&);
jsbell 2014/04/14 18:35:39 Chromium style is to use pointers, not non-const r
virtual leveldb::Status GetIDBDatabaseMetaData(
const base::string16& name,
IndexedDBDatabaseMetadata* metadata,
@@ -260,15 +260,18 @@ class CONTENT_EXPORT IndexedDBBackingStore
};
const IndexedDBKey& key() const { return *current_key_; }
- bool Continue() { return Continue(NULL, NULL, SEEK); }
- bool Continue(const IndexedDBKey* key, IteratorState state) {
- return Continue(key, NULL, state);
+ bool Continue(leveldb::Status& s) { return Continue(NULL, NULL, SEEK, s); }
+ bool Continue(const IndexedDBKey* key,
+ IteratorState state,
+ leveldb::Status& s) {
+ return Continue(key, NULL, state, s);
}
bool Continue(const IndexedDBKey* key,
const IndexedDBKey* primary_key,
- IteratorState state);
- bool Advance(uint32 count);
- bool FirstSeek();
+ IteratorState state,
+ leveldb::Status&);
+ bool Advance(uint32 count, leveldb::Status&);
+ bool FirstSeek(leveldb::Status&);
virtual Cursor* Clone() = 0;
virtual const IndexedDBKey& primary_key() const;
@@ -300,27 +303,31 @@ class CONTENT_EXPORT IndexedDBBackingStore
int64 database_id,
int64 object_store_id,
const IndexedDBKeyRange& key_range,
- indexed_db::CursorDirection);
+ indexed_db::CursorDirection,
+ leveldb::Status&);
virtual scoped_ptr<Cursor> OpenObjectStoreCursor(
IndexedDBBackingStore::Transaction* transaction,
int64 database_id,
int64 object_store_id,
const IndexedDBKeyRange& key_range,
- indexed_db::CursorDirection);
+ indexed_db::CursorDirection,
+ leveldb::Status&);
virtual scoped_ptr<Cursor> OpenIndexKeyCursor(
IndexedDBBackingStore::Transaction* transaction,
int64 database_id,
int64 object_store_id,
int64 index_id,
const IndexedDBKeyRange& key_range,
- indexed_db::CursorDirection);
+ indexed_db::CursorDirection,
+ leveldb::Status& s);
virtual scoped_ptr<Cursor> OpenIndexCursor(
IndexedDBBackingStore::Transaction* transaction,
int64 database_id,
int64 object_store_id,
int64 index_id,
const IndexedDBKeyRange& key_range,
- indexed_db::CursorDirection);
+ indexed_db::CursorDirection,
+ leveldb::Status&);
class Transaction {
public:

Powered by Google App Engine
This is Rietveld 408576698