Changeset 20194 in webkit


Ignore:
Timestamp:
Mar 14, 2007 1:38:28 PM (17 years ago)
Author:
antti
Message:

Reviewed by Geoff.

Fix http://bugs.webkit.org/show_bug.cgi?id=13060
REGRESSION: Repro ASSERT failure in Cache::adjustSize running layout tests
<rdar://5060208>


Script evaluation may have dereffed the CachedScript object already, causing double deref and
eventually m_liveResourcesSize underflow.

  • html/HTMLScriptElement.cpp: (WebCore::HTMLScriptElement::notifyFinished):
Location:
trunk/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r20193 r20194  
     12007-03-14  Antti Koivisto  <antti@apple.com>
     2
     3        Reviewed by Geoff.
     4
     5        Fix http://bugs.webkit.org/show_bug.cgi?id=13060
     6        REGRESSION: Repro ASSERT failure in Cache::adjustSize running layout tests
     7        <rdar://5060208>
     8       
     9        Script evaluation may have dereffed the CachedScript object already, causing double deref and
     10        eventually m_liveResourcesSize underflow.
     11
     12        * html/HTMLScriptElement.cpp:
     13        (WebCore::HTMLScriptElement::notifyFinished):
     14
    1152007-03-14  Adele Peterson  <adele@apple.com>
    216
  • trunk/WebCore/html/HTMLScriptElement.cpp

    r18867 r20194  
    156156    }
    157157
    158     cs->deref(this);
    159     m_cachedScript = 0;
     158    // script evaluation may have dereffed it already
     159    if (m_cachedScript) {
     160        m_cachedScript->deref(this);
     161        m_cachedScript = 0;
     162    }
    160163}
    161164
Note: See TracChangeset for help on using the changeset viewer.