Reviewed by Darin.
authoradele@apple.com <adele@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Nov 2007 02:15:10 +0000 (02:15 +0000)
committeradele@apple.com <adele@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Nov 2007 02:15:10 +0000 (02:15 +0000)
        Update to last change.  Moved addPendingSheet call to within nil check for m_cachedSheet.

        * page/Frame.cpp:
        (WebCore::UserStyleSheetLoader::UserStyleSheetLoader):

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

WebCore/ChangeLog
WebCore/page/Frame.cpp

index 9f1d849..e4a8a6d 100644 (file)
@@ -2,6 +2,15 @@
 
         Reviewed by Darin.
 
+        Update to last change.  Moved addPendingSheet call to within nil check for m_cachedSheet.
+
+        * page/Frame.cpp:
+        (WebCore::UserStyleSheetLoader::UserStyleSheetLoader):
+
+2007-11-26  Adele Peterson  <adele@apple.com>
+
+        Reviewed by Darin.
+
         Fix for <rdar://problem/5591583> CrashTracer: [USER] 157 in Mail crashes at -[WebCoreFrameBridge reapplyStylesForDeviceType:]
 
         * page/Frame.cpp: Add nil checks since every other caller of requestCSSStyleSheet checks for nil.
index 337233c..61155b6 100644 (file)
@@ -98,9 +98,10 @@ public:
         : m_document(document)
         , m_cachedSheet(m_document->docLoader()->requestUserCSSStyleSheet(url, ""))
     {
-        m_document->addPendingSheet();
-        if (m_cachedSheet)
+        if (m_cachedSheet) {
+            m_document->addPendingSheet();
             m_cachedSheet->ref(this);
+        }
     }
     ~UserStyleSheetLoader()
     {