Title: [97826] trunk/Source/_javascript_Core
Revision
97826
Author
[email protected]
Date
2011-10-18 18:50:14 -0700 (Tue, 18 Oct 2011)

Log Message

Errrk, fix partial commit of r97825!

* runtime/DatePrototype.cpp:
(JSC::dateProtoFuncToISOString):

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (97825 => 97826)


--- trunk/Source/_javascript_Core/ChangeLog	2011-10-19 01:49:13 UTC (rev 97825)
+++ trunk/Source/_javascript_Core/ChangeLog	2011-10-19 01:50:14 UTC (rev 97826)
@@ -1,5 +1,12 @@
 2011-10-18  Gavin Barraclough  <[email protected]>
 
+        Errrk, fix partial commit of r97825!
+
+        * runtime/DatePrototype.cpp:
+        (JSC::dateProtoFuncToISOString):
+
+2011-10-18  Gavin Barraclough  <[email protected]>
+
         Date.prototype.toISOString fails to throw exception
         https://bugs.webkit.org/show_bug.cgi?id=70394
 

Modified: trunk/Source/_javascript_Core/runtime/DatePrototype.cpp (97825 => 97826)


--- trunk/Source/_javascript_Core/runtime/DatePrototype.cpp	2011-10-19 01:49:13 UTC (rev 97825)
+++ trunk/Source/_javascript_Core/runtime/DatePrototype.cpp	2011-10-19 01:50:14 UTC (rev 97826)
@@ -503,7 +503,9 @@
         return throwVMTypeError(exec);
     
     DateInstance* thisDateObj = asDateInstance(thisValue); 
-    
+    if (!isfinite(thisDateObj->internalNumber()))
+        return throwVMError(exec, createRangeError(exec, "Invalid Date"));
+
     const GregorianDateTime* gregorianDateTime = thisDateObj->gregorianDateTimeUTC(exec);
     if (!gregorianDateTime)
         return JSValue::encode(jsNontrivialString(exec, "Invalid Date"));
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to