REGRESSION(r179476): It broke the !ENABLE(PICTURE_SIZES) build
authordarin@apple.com <darin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 11 Feb 2015 16:41:13 +0000 (16:41 +0000)
committerdarin@apple.com <darin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 11 Feb 2015 16:41:13 +0000 (16:41 +0000)
https://bugs.webkit.org/show_bug.cgi?id=141327

Reviewed by Csaba Osztrogon√°c.

* html/parser/HTMLPreloadScanner.cpp:
(WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
Put #if around use of m_sizesAttribute.

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

Source/WebCore/ChangeLog
Source/WebCore/html/parser/HTMLPreloadScanner.cpp

index 28da8e6..9b632a8 100644 (file)
@@ -1,3 +1,14 @@
+2015-02-11  Darin Adler  <darin@apple.com>
+
+        REGRESSION(r179476): It broke the !ENABLE(PICTURE_SIZES) build
+        https://bugs.webkit.org/show_bug.cgi?id=141327
+
+        Reviewed by Csaba Osztrogon√°c.
+
+        * html/parser/HTMLPreloadScanner.cpp:
+        (WebCore::TokenPreloadScanner::StartTagScanner::processAttributes):
+        Put #if around use of m_sizesAttribute.
+
 2015-02-11  Commit Queue  <commit-queue@webkit.org>
 
         Unreviewed, rolling out r179921.
index f0e88e7..7d80cf7 100644 (file)
@@ -107,7 +107,10 @@ public:
 
         // Resolve between src and srcSet if we have them.
         if (!m_srcSetAttribute.isEmpty()) {
-            unsigned sourceSize = parseSizesAttribute(m_sizesAttribute, document.renderView(), document.frame());
+            unsigned sourceSize = 0;
+#if ENABLE(PICTURE_SIZES)
+            sourceSize = parseSizesAttribute(m_sizesAttribute, document.renderView(), document.frame());
+#endif
             ImageCandidate imageCandidate = bestFitSourceForImageAttributes(m_deviceScaleFactor, m_urlToLoad, m_srcSetAttribute, sourceSize);
             setUrlToLoad(imageCandidate.string.toString(), true);
         }