Changeset 195783 in webkit
- Timestamp:
- Jan 28, 2016 2:40:02 PM (8 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r195780 r195783 1 2016-01-28 Brady Eidson <beidson@apple.com> 2 3 Modern IDB: SQLite backend doesn't support deleting ranges with more than one key. 4 https://bugs.webkit.org/show_bug.cgi?id=153604 5 6 Reviewed by Andy Estes. 7 8 * platform/mac-wk1/TestExpectations: 9 1 10 2016-01-28 Carlos Alberto Lopez Perez <clopez@igalia.com> 2 11 -
trunk/LayoutTests/platform/mac-wk1/TestExpectations
r195765 r195783 456 456 storage/indexeddb/cursor-primary-key-order.html [ Failure ] 457 457 storage/indexeddb/cursor-update.html [ Failure ] 458 storage/indexeddb/delete-range.html [ Failure ]459 458 storage/indexeddb/get-keyrange.html [ Failure ] 460 459 storage/indexeddb/index-duplicate-keypaths.html [ Failure ] … … 462 461 storage/indexeddb/modern/cursor-7.html [ Failure ] 463 462 storage/indexeddb/modern/get-keyrange.html [ Failure ] 464 storage/indexeddb/modern/idbobjectstore-delete-1.html [ Failure ]465 463 storage/indexeddb/modern/index-3.html [ Failure ] 466 464 storage/indexeddb/mozilla/cursor-mutation.html [ Failure ] -
trunk/Source/WebCore/ChangeLog
r195782 r195783 1 2016-01-28 Brady Eidson <beidson@apple.com> 2 3 Modern IDB: SQLite backend doesn't support deleting ranges with more than one key. 4 https://bugs.webkit.org/show_bug.cgi?id=153604 5 6 Reviewed by Andy Estes. 7 8 No new tests (A few failing tests pass, a few get closer). 9 10 * Modules/indexeddb/server/SQLiteIDBBackingStore.cpp: 11 (WebCore::IDBServer::SQLiteIDBBackingStore::deleteRange): 12 1 13 2016-01-28 Alex Christensen <achristensen@webkit.org> 2 14 -
trunk/Source/WebCore/Modules/indexeddb/server/SQLiteIDBBackingStore.cpp
r195765 r195783 1030 1030 } 1031 1031 1032 // FIXME: Once cursor support is in place, use a cursor to delete every record in the range. 1033 LOG_ERROR("Currently unable to delete all records in a multi-key range"); 1034 return { IDBDatabaseException::UnknownError, ASCIILiteral("Currently unable to delete all records in a multi-key range") }; 1032 auto cursor = transaction->maybeOpenBackingStoreCursor(objectStoreID, 0, keyRange); 1033 if (!cursor) { 1034 LOG_ERROR("Cannot open cursor to delete range of records from the database"); 1035 return { IDBDatabaseException::UnknownError, ASCIILiteral("Cannot open cursor to delete range of records from the database") }; 1036 } 1037 1038 Vector<IDBKeyData> keys; 1039 while (!cursor->didComplete() && !cursor->didError()) { 1040 keys.append(cursor->currentKey()); 1041 cursor->advance(1); 1042 } 1043 1044 if (cursor->didError()) { 1045 LOG_ERROR("Cursor failed while accumulating range of records from the database"); 1046 return { IDBDatabaseException::UnknownError, ASCIILiteral("Cursor failed while accumulating range of records from the database") }; 1047 } 1048 1049 IDBError error; 1050 for (auto& key : keys) { 1051 error = deleteRecord(*transaction, objectStoreID, key); 1052 if (!error.isNull()) { 1053 LOG_ERROR("deleteRange: Error deleting keys in range"); 1054 break; 1055 } 1056 } 1057 1058 return error; 1035 1059 } 1036 1060
Note: See TracChangeset
for help on using the changeset viewer.