Title: [177823] trunk/Source/WebKit2
Revision
177823
Author
ander...@apple.com
Date
2014-12-30 09:41:13 -0800 (Tue, 30 Dec 2014)

Log Message

Transient local storage namespaces need to ref their storage areas
https://bugs.webkit.org/show_bug.cgi?id=140006
<rdar://problem/19225389>

Reviewed by Sam Weinig.

We need to keep transient storage areas around even if they have no active connections,
so use a RefPtr instead of a raw pointer. This matches what we do for session storage namespaces.

* UIProcess/Storage/StorageManager.cpp:

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (177822 => 177823)


--- trunk/Source/WebKit2/ChangeLog	2014-12-30 12:29:16 UTC (rev 177822)
+++ trunk/Source/WebKit2/ChangeLog	2014-12-30 17:41:13 UTC (rev 177823)
@@ -1,3 +1,16 @@
+2014-12-30  Anders Carlsson  <ander...@apple.com>
+
+        Transient local storage namespaces need to ref their storage areas
+        https://bugs.webkit.org/show_bug.cgi?id=140006
+        <rdar://problem/19225389>
+
+        Reviewed by Sam Weinig.
+
+        We need to keep transient storage areas around even if they have no active connections,
+        so use a RefPtr instead of a raw pointer. This matches what we do for session storage namespaces.
+
+        * UIProcess/Storage/StorageManager.cpp:
+
 2014-12-29  Anders Carlsson  <ander...@apple.com>
 
         Remove unneeded StorageNamespace functions

Modified: trunk/Source/WebKit2/UIProcess/Storage/StorageManager.cpp (177822 => 177823)


--- trunk/Source/WebKit2/UIProcess/Storage/StorageManager.cpp	2014-12-30 12:29:16 UTC (rev 177822)
+++ trunk/Source/WebKit2/UIProcess/Storage/StorageManager.cpp	2014-12-30 17:41:13 UTC (rev 177823)
@@ -150,8 +150,7 @@
 
     const unsigned m_quotaInBytes = 5 * 1024 * 1024;
 
-    // We don't hold an explicit reference to the StorageAreas; they are kept alive by the m_storageAreasByConnection map in StorageManager.
-    HashMap<RefPtr<SecurityOrigin>, StorageArea*> m_storageAreaMap;
+    HashMap<RefPtr<SecurityOrigin>, RefPtr<StorageArea>> m_storageAreaMap;
 };
 
 Ref<StorageManager::StorageArea> StorageManager::StorageArea::create(LocalStorageNamespace* localStorageNamespace, RefPtr<SecurityOrigin>&& securityOrigin, unsigned quotaInBytes)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to