Title: [163912] trunk
- Revision
- 163912
- Author
- [email protected]
- Date
- 2014-02-11 15:01:09 -0800 (Tue, 11 Feb 2014)
Log Message
IDB: The test after storage/indexeddb/mozilla/object-identity.html fails in cleanup code
<rdar://problem/16040663> and https://bugs.webkit.org/show_bug.cgi?id=128621
Reviewed by Alexey Proskuryakov.
Source/WebCore:
Covered by storage/indexeddb/mozilla/object-identity.html.
* Modules/indexeddb/IDBTransactionBackend.cpp:
(WebCore::IDBTransactionBackend::abort): Clear the m_database pointer before calling the onAbort callback.
(WebCore::IDBTransactionBackend::commit): Don't run the abort code if there's no m_database pointer.
LayoutTests:
* platform/mac-wk2/TestExpectations: Enabled all of the storage/indexeddb/mozilla tests except 1.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (163911 => 163912)
--- trunk/LayoutTests/ChangeLog 2014-02-11 22:56:25 UTC (rev 163911)
+++ trunk/LayoutTests/ChangeLog 2014-02-11 23:01:09 UTC (rev 163912)
@@ -1,3 +1,12 @@
+2014-02-11 Brady Eidson <[email protected]>
+
+ IDB: The test after storage/indexeddb/mozilla/object-identity.html fails in cleanup code
+ <rdar://problem/16040663> and https://bugs.webkit.org/show_bug.cgi?id=128621
+
+ Reviewed by Alexey Proskuryakov.
+
+ * platform/mac-wk2/TestExpectations: Enabled all of the storage/indexeddb/mozilla tests except 1.
+
2014-02-11 Diego Pino Garcia <[email protected]>
Unreviewed. Fix typo in layout test introduced in r163811.
Modified: trunk/LayoutTests/platform/mac-wk2/TestExpectations (163911 => 163912)
--- trunk/LayoutTests/platform/mac-wk2/TestExpectations 2014-02-11 22:56:25 UTC (rev 163911)
+++ trunk/LayoutTests/platform/mac-wk2/TestExpectations 2014-02-11 23:01:09 UTC (rev 163912)
@@ -470,21 +470,42 @@
fullscreen/anonymous-block-merge-crash.html [ Pass ]
# All IndexedDB tests are skipped in WK1.
-# Reenable individual tests here that are known to pass, with the eventual goal of re-enabling the entire directory.
-# (Except, skip them for now since https://bugs.webkit.org/show_bug.cgi?id=128341 is getting in the way of testing in general)
+# Until we have a WK1 specific skipped file that WK2 doesn't inherit from,
+# we'll reenable individual tests that are known to pass.
storage/indexeddb/mozilla/add-twice-failure.html [ Pass ]
storage/indexeddb/mozilla/autoincrement-indexes.html [ Pass ]
+storage/indexeddb/mozilla/bad-keypath.html [ Pass ]
storage/indexeddb/mozilla/clear.html [ Pass ]
+storage/indexeddb/mozilla/create-index-unique.html [ Pass ]
storage/indexeddb/mozilla/create-index-with-integer-keys.html [ Pass ]
+storage/indexeddb/mozilla/create-objectstore-basics.html [ Pass ]
+storage/indexeddb/mozilla/create-objectstore-null-name.html [ Pass ]
storage/indexeddb/mozilla/cursor-mutation-objectstore-only.html [ Pass ]
storage/indexeddb/mozilla/cursor-mutation.html [ Pass ]
storage/indexeddb/mozilla/cursor-update-updates-indexes.html [ Pass ]
storage/indexeddb/mozilla/cursors.html [ Pass ]
+storage/indexeddb/mozilla/delete-result.html [ Pass ]
+storage/indexeddb/mozilla/event-source.html [ Pass ]
storage/indexeddb/mozilla/index-prev-no-duplicate.html [ Pass ]
storage/indexeddb/mozilla/indexes.html [ Pass ]
+storage/indexeddb/mozilla/key-requirements-delete-null-key.html [ Pass ]
+storage/indexeddb/mozilla/key-requirements-inline-and-passed.html [ Pass ]
+storage/indexeddb/mozilla/key-requirements-put-no-key.html [ Pass ]
+storage/indexeddb/mozilla/key-requirements-put-null-key.html [ Pass ]
+storage/indexeddb/mozilla/key-requirements.html [ Pass ]
storage/indexeddb/mozilla/object-cursors.html [ Pass ]
+storage/indexeddb/mozilla/object-identity.html [ Pass ]
storage/indexeddb/mozilla/object-store-inline-autoincrement-key-added-on-put.html [ Pass ]
storage/indexeddb/mozilla/object-store-remove-values.html [ Pass ]
+storage/indexeddb/mozilla/objectstorenames.html [ Pass ]
+storage/indexeddb/mozilla/odd-result-order.html [ Pass ]
+storage/indexeddb/mozilla/open-database-null-name.html [ Pass ]
+storage/indexeddb/mozilla/put-get-values.html [ Pass ]
+storage/indexeddb/mozilla/readonly-transactions.html [ Pass ]
+storage/indexeddb/mozilla/readwrite-transactions.html [ Pass ]
+storage/indexeddb/mozilla/readyState.html [ Pass ]
+storage/indexeddb/mozilla/remove-index.html [ Pass ]
+storage/indexeddb/mozilla/remove-objectstore.html [ Pass ]
storage/indexeddb/mozilla/versionchange-abort.html [ Pass ]
### END OF (5) Features that are not supported in WebKit1, so skipped in mac/TestExpectations then re-enabled here
Modified: trunk/Source/WebCore/ChangeLog (163911 => 163912)
--- trunk/Source/WebCore/ChangeLog 2014-02-11 22:56:25 UTC (rev 163911)
+++ trunk/Source/WebCore/ChangeLog 2014-02-11 23:01:09 UTC (rev 163912)
@@ -1,3 +1,16 @@
+2014-02-11 Brady Eidson <[email protected]>
+
+ IDB: The test after storage/indexeddb/mozilla/object-identity.html fails in cleanup code
+ <rdar://problem/16040663> and https://bugs.webkit.org/show_bug.cgi?id=128621
+
+ Reviewed by Alexey Proskuryakov.
+
+ Covered by storage/indexeddb/mozilla/object-identity.html.
+
+ * Modules/indexeddb/IDBTransactionBackend.cpp:
+ (WebCore::IDBTransactionBackend::abort): Clear the m_database pointer before calling the onAbort callback.
+ (WebCore::IDBTransactionBackend::commit): Don't run the abort code if there's no m_database pointer.
+
2014-02-10 Jer Noble <[email protected]>
[EME][Mac] Move the implementation of CDMPrivateAVFoundation back into MediaPlayerPrivateAVFoundationObjC.
Modified: trunk/Source/WebCore/Modules/indexeddb/IDBTransactionBackend.cpp (163911 => 163912)
--- trunk/Source/WebCore/Modules/indexeddb/IDBTransactionBackend.cpp 2014-02-11 22:56:25 UTC (rev 163911)
+++ trunk/Source/WebCore/Modules/indexeddb/IDBTransactionBackend.cpp 2014-02-11 23:01:09 UTC (rev 163912)
@@ -158,12 +158,12 @@
ASSERT(!m_database->transactionCoordinator()->isActive(this));
m_database->transactionFinished(this);
+ RefPtr<IDBDatabaseBackend> database = m_database.release();
+
if (m_callbacks)
m_callbacks->onAbort(id(), error);
- m_database->transactionFinishedAndAbortFired(this);
-
- m_database = 0;
+ database->transactionFinishedAndAbortFired(this);
}
bool IDBTransactionBackend::isTaskQueueEmpty() const
@@ -235,6 +235,14 @@
bool committed = unused;
m_database->serverConnection().commitTransaction(m_id, [backend, this, committed, unused](bool success) mutable {
+ // This might be commitTransaction request aborting during or after synchronous IDBTransactionBackend::abort() call.
+ // This can easily happen if the page is navigated before all transactions finish.
+ // In this case we have no further cleanup and don't need to make any callbacks.
+ if (!m_database) {
+ ASSERT(!success);
+ return;
+ }
+
committed |= success;
// Backing store resources (held via cursors) must be released before script callbacks
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes