[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

eric at webkit.org eric at webkit.org
Thu Apr 8 00:41:16 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 83e2be495acda16e6f0f8e12dd6fbcc85d33df3e
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Dec 17 22:37:17 2009 +0000

    2009-12-17  Steve Block  <steveblock at google.com>
    
            Reviewed by Eric Seidel.
    
            Fixes HTMLInputElement::stepMismatch() to avoid ambiguous overload of pow().
            https://bugs.webkit.org/show_bug.cgi?id=32675
    
            Build fix only, no new tests.
    
            * html/HTMLInputElement.cpp: Modified.
            (WebCore::HTMLInputElement::stepMismatch): Cast first argument of pow to double to force 'double pow(double, int)'
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@52292 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 051b96d..2ba0cbc 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,15 @@
+2009-12-17  Steve Block  <steveblock at google.com>
+
+        Reviewed by Eric Seidel.
+
+        Fixes HTMLInputElement::stepMismatch() to avoid ambiguous overload of pow().
+        https://bugs.webkit.org/show_bug.cgi?id=32675
+
+        Build fix only, no new tests.
+
+        * html/HTMLInputElement.cpp: Modified.
+        (WebCore::HTMLInputElement::stepMismatch): Cast first argument of pow to double to force 'double pow(double, int)'
+
 2009-12-17  Marc-Antoine Ruel  <maruel at chromium.org>
 
         Reviewed by Eric Seidel.
diff --git a/WebCore/html/HTMLInputElement.cpp b/WebCore/html/HTMLInputElement.cpp
index 227ad9c..602b339 100644
--- a/WebCore/html/HTMLInputElement.cpp
+++ b/WebCore/html/HTMLInputElement.cpp
@@ -337,11 +337,11 @@ bool HTMLInputElement::stepMismatch() const
         // double's fractional part size is DBL_MAN_DIG-bit.  If the current
         // value is greater than step*2^DBL_MANT_DIG, the following fmod() makes
         // no sense.
-        if (doubleValue / pow(2, DBL_MANT_DIG) > step)
+        if (doubleValue / pow(static_cast<double>(2), DBL_MANT_DIG) > step)
             return false;
         double remainder = fmod(doubleValue, step);
         // Accepts errors in lower 7-bit.
-        double acceptableError = step / pow(2, DBL_MANT_DIG - 7);
+        double acceptableError = step / pow(static_cast<double>(2), DBL_MANT_DIG - 7);
         return acceptableError < remainder && remainder < (step - acceptableError);
     }
     // Non-RANGE types should be rejected by getAllowedValueStep().

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list