Skip to content

Commit

Permalink
Merge r174014 - StorageTracker::deleteOrigin being called off the mai…
Browse files Browse the repository at this point in the history
…n thread (ASSERTs in inspector/test-harness-trivially-works.html test)

https://bugs.webkit.org/show_bug.cgi?id=129642

Apply post-review comments from Alexey Proskuryakov.

* storage/StorageAreaSync.cpp:
(WebCore::StorageAreaSync::deleteEmptyDatabase): Make a thread-safe isolated copy of the string.

Canonical link: https://commits.webkit.org/154760.55@webkitgtk/2.6
git-svn-id: https://svn.webkit.org/repository/webkit/releases/WebKitGTK/webkit-2.6@174442 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
BJ Burg authored and carlosgcampos committed Oct 8, 2014
1 parent 424b6d6 commit a24670a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
10 changes: 10 additions & 0 deletions Source/WebCore/ChangeLog
@@ -1,3 +1,13 @@
2014-09-26 Brian J. Burg <burg@cs.washington.edu>

StorageTracker::deleteOrigin being called off the main thread (ASSERTs in inspector/test-harness-trivially-works.html test)
https://bugs.webkit.org/show_bug.cgi?id=129642

Apply post-review comments from Alexey Proskuryakov.

* storage/StorageAreaSync.cpp:
(WebCore::StorageAreaSync::deleteEmptyDatabase): Make a thread-safe isolated copy of the string.

2014-09-25 Brian J. Burg <burg@cs.washington.edu>

StorageTracker::deleteOrigin being called off the main thread (ASSERTs in inspector/test-harness-trivially-works.html test)
Expand Down
6 changes: 4 additions & 2 deletions Source/WebCore/storage/StorageAreaSync.cpp
Expand Up @@ -522,8 +522,10 @@ void StorageAreaSync::deleteEmptyDatabase()
query.finalize();
m_database.close();
if (StorageTracker::tracker().isActive()) {
callOnMainThread([this] {
StorageTracker::tracker().deleteOriginWithIdentifier(m_databaseIdentifier);
StringImpl* databaseIdentifierCopy = &m_databaseIdentifier.impl()->isolatedCopy().leakRef();
callOnMainThread([databaseIdentifierCopy] {
StorageTracker::tracker().deleteOriginWithIdentifier(databaseIdentifierCopy);
databaseIdentifierCopy->deref();
});
} else {
String databaseFilename = m_syncManager->fullDatabaseFilename(m_databaseIdentifier);
Expand Down

0 comments on commit a24670a

Please sign in to comment.