Reorder the call to allReferencesRemoved, since otherwise the live object...
authorhyatt <hyatt@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 13 Mar 2007 22:03:36 +0000 (22:03 +0000)
committerhyatt <hyatt@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 13 Mar 2007 22:03:36 +0000 (22:03 +0000)
        incorrect.

        * loader/CachedResource.cpp:
        (WebCore::CachedResource::deref):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@20163 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebCore/ChangeLog
WebCore/loader/CachedResource.cpp

index 70671aff95c609e660171e3bfc5f579a83419da1..94da88ee761636794cb0996276456c87fd3f4a20 100644 (file)
@@ -1,3 +1,11 @@
+2007-03-13  David Hyatt  <hyatt@apple.com>
+
+        Reorder the call to allReferencesRemoved, since otherwise the live object size will become
+        incorrect.
+
+        * loader/CachedResource.cpp:
+        (WebCore::CachedResource::deref):
+
 2007-03-13  Antti Koivisto  <antti@apple.com>
 
         Reviewed by Darin.
index 33a269b4a48dab937bd85b16f67548ee16c1c020..eb0b1907ec16338a6264cb00d35cce9991ffb53a 100644 (file)
@@ -119,8 +119,8 @@ void CachedResource::deref(CachedResourceClient *c)
     if (canDelete() && !inCache())
         delete this;
     else if (!referenced() && inCache()) {
-        allReferencesRemoved();
         cache()->removeFromLiveObjectSize(size());
+        allReferencesRemoved();
         cache()->prune();
     }
 }