Title: [93011] trunk/Source/WebCore
Revision
93011
Author
[email protected]
Date
2011-08-12 18:44:01 -0700 (Fri, 12 Aug 2011)

Log Message

Abandoned Memory: Temporary CSS Fonts May Never Be Purged
https://bugs.webkit.org/show_bug.cgi?id=66153

Reviewed by Dan Bernstein.

No new tests, this is not a functional change.

* css/CSSFontFaceSource.cpp:
(WebCore::CSSFontFaceSource::getFontData):
If the CSS font-face is loading from a URL then immediately
fallback to a system font matching the description, since we
cannot determine a reasonable family name from the m_string
URL. The URL could be a dataURI.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (93010 => 93011)


--- trunk/Source/WebCore/ChangeLog	2011-08-12 23:27:45 UTC (rev 93010)
+++ trunk/Source/WebCore/ChangeLog	2011-08-13 01:44:01 UTC (rev 93011)
@@ -1,3 +1,19 @@
+2011-08-12  Joseph Pecoraro  <[email protected]>
+
+        Abandoned Memory: Temporary CSS Fonts May Never Be Purged
+        https://bugs.webkit.org/show_bug.cgi?id=66153
+
+        Reviewed by Dan Bernstein.
+
+        No new tests, this is not a functional change.
+
+        * css/CSSFontFaceSource.cpp:
+        (WebCore::CSSFontFaceSource::getFontData):
+        If the CSS font-face is loading from a URL then immediately
+        fallback to a system font matching the description, since we
+        cannot determine a reasonable family name from the m_string
+        URL. The URL could be a dataURI.
+
 2011-08-12  Fady Samuel  <[email protected]>
 
         Refactoring of PopupMenuChromium For Readability and Maintainability

Modified: trunk/Source/WebCore/css/CSSFontFaceSource.cpp (93010 => 93011)


--- trunk/Source/WebCore/css/CSSFontFaceSource.cpp	2011-08-12 23:27:45 UTC (rev 93010)
+++ trunk/Source/WebCore/css/CSSFontFaceSource.cpp	2011-08-13 01:44:01 UTC (rev 93011)
@@ -185,11 +185,7 @@
         if (!m_loadStartTimer.isActive())
             m_loadStartTimer.startOneShot(0);
 
-        // FIXME: m_string is a URL so it makes no sense to pass it as a family name.
-        SimpleFontData* tempData = fontCache()->getCachedFontData(fontDescription, m_string);
-        if (!tempData)
-            tempData = fontCache()->getLastResortFallbackFont(fontDescription);
-
+        SimpleFontData* tempData = fontCache()->getLastResortFallbackFont(fontDescription);
         fontData = adoptPtr(new SimpleFontData(tempData->platformData(), true, true));
     }
 
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to