| Index: content/browser/indexed_db/indexed_db_database.cc
|
| diff --git a/content/browser/indexed_db/indexed_db_database.cc b/content/browser/indexed_db/indexed_db_database.cc
|
| index a7d5da06d2b04fdc8ba03223d15490f581a5717e..e2d4df2c7e38f896d2fac29aa3c42e6b8c369e65 100644
|
| --- a/content/browser/indexed_db/indexed_db_database.cc
|
| +++ b/content/browser/indexed_db/indexed_db_database.cc
|
| @@ -1206,42 +1206,22 @@ void IndexedDBDatabase::DeleteRangeOperation(
|
| scoped_refptr<IndexedDBCallbacks> callbacks,
|
| IndexedDBTransaction* transaction) {
|
| IDB_TRACE("IndexedDBDatabase::DeleteRangeOperation");
|
| - leveldb::Status s;
|
| - scoped_ptr<IndexedDBBackingStore::Cursor> backing_store_cursor =
|
| - backing_store_->OpenObjectStoreCursor(
|
| - transaction->BackingStoreTransaction(),
|
| - id(),
|
| - object_store_id,
|
| - *key_range,
|
| - indexed_db::CURSOR_NEXT,
|
| - &s);
|
| - if (backing_store_cursor && s.ok()) {
|
| - do {
|
| - if (!backing_store_->DeleteRecord(
|
| - transaction->BackingStoreTransaction(),
|
| - id(),
|
| - object_store_id,
|
| - backing_store_cursor->record_identifier())
|
| - .ok()) {
|
| - callbacks->OnError(
|
| - IndexedDBDatabaseError(blink::WebIDBDatabaseExceptionUnknownError,
|
| - "Internal error deleting data in range"));
|
| - return;
|
| - }
|
| - } while (backing_store_cursor->Continue(&s));
|
| - }
|
| -
|
| + leveldb::Status s =
|
| + backing_store_->DeleteRange(transaction->BackingStoreTransaction(),
|
| + id(),
|
| + object_store_id,
|
| + *key_range);
|
| if (!s.ok()) {
|
| + base::string16 error_string =
|
| + ASCIIToUTF16("Internal error deleting data in range");
|
| IndexedDBDatabaseError error(blink::WebIDBDatabaseExceptionUnknownError,
|
| - ASCIIToUTF16("Internal error deleting range"));
|
| + error_string);
|
| transaction->Abort(error);
|
| - if (s.IsCorruption()) {
|
| + if (s.IsCorruption())
|
| factory_->HandleBackingStoreCorruption(backing_store_->origin_url(),
|
| error);
|
| - }
|
| return;
|
| }
|
| -
|
| callbacks->OnSuccess();
|
| }
|
|
|
|
|