Title: [271568] trunk
Revision
271568
Author
[email protected]
Date
2021-01-17 22:03:32 -0800 (Sun, 17 Jan 2021)

Log Message

[JSC] Add some more exception checks in globalFuncCopyDataProperties
https://bugs.webkit.org/show_bug.cgi?id=220691

Reviewed by Mark Lam.

JSTests:

* stress/spread-object-check.js: Added.
* stress/spread-object-check2.js: Added.

Source/_javascript_Core:

This patch add some missing exception checks in globalFuncCopyDataProperties to fix tests attached in this patch.

* runtime/JSGlobalObjectFunctions.cpp:
(JSC::JSC_DEFINE_HOST_FUNCTION):

Modified Paths

Added Paths

Diff

Modified: trunk/JSTests/ChangeLog (271567 => 271568)


--- trunk/JSTests/ChangeLog	2021-01-18 04:09:31 UTC (rev 271567)
+++ trunk/JSTests/ChangeLog	2021-01-18 06:03:32 UTC (rev 271568)
@@ -1,3 +1,13 @@
+2021-01-17  Yusuke Suzuki  <[email protected]>
+
+        [JSC] Add some more exception checks in globalFuncCopyDataProperties
+        https://bugs.webkit.org/show_bug.cgi?id=220691
+
+        Reviewed by Mark Lam.
+
+        * stress/spread-object-check.js: Added.
+        * stress/spread-object-check2.js: Added.
+
 2021-01-14  Ross Kirsling  <[email protected]>
 
         Unreviewed. Add skips for Big Sur-dependent test262 tests.

Added: trunk/JSTests/stress/spread-object-check.js (0 => 271568)


--- trunk/JSTests/stress/spread-object-check.js	                        (rev 0)
+++ trunk/JSTests/stress/spread-object-check.js	2021-01-18 06:03:32 UTC (rev 271568)
@@ -0,0 +1,2 @@
+let z = new Uint8Array(4);
+({...z});

Added: trunk/JSTests/stress/spread-object-check2.js (0 => 271568)


--- trunk/JSTests/stress/spread-object-check2.js	                        (rev 0)
+++ trunk/JSTests/stress/spread-object-check2.js	2021-01-18 06:03:32 UTC (rev 271568)
@@ -0,0 +1,5 @@
+let o = {
+  1234: undefined
+};
+
+({...o});

Modified: trunk/Source/_javascript_Core/ChangeLog (271567 => 271568)


--- trunk/Source/_javascript_Core/ChangeLog	2021-01-18 04:09:31 UTC (rev 271567)
+++ trunk/Source/_javascript_Core/ChangeLog	2021-01-18 06:03:32 UTC (rev 271568)
@@ -1,5 +1,17 @@
 2021-01-17  Yusuke Suzuki  <[email protected]>
 
+        [JSC] Add some more exception checks in globalFuncCopyDataProperties
+        https://bugs.webkit.org/show_bug.cgi?id=220691
+
+        Reviewed by Mark Lam.
+
+        This patch add some missing exception checks in globalFuncCopyDataProperties to fix tests attached in this patch.
+
+        * runtime/JSGlobalObjectFunctions.cpp:
+        (JSC::JSC_DEFINE_HOST_FUNCTION):
+
+2021-01-17  Yusuke Suzuki  <[email protected]>
+
         Add JSC API configuring GC signals in Linux
         https://bugs.webkit.org/show_bug.cgi?id=220641
 

Modified: trunk/Source/_javascript_Core/runtime/JSGlobalObjectFunctions.cpp (271567 => 271568)


--- trunk/Source/_javascript_Core/runtime/JSGlobalObjectFunctions.cpp	2021-01-18 04:09:31 UTC (rev 271567)
+++ trunk/Source/_javascript_Core/runtime/JSGlobalObjectFunctions.cpp	2021-01-18 06:03:32 UTC (rev 271568)
@@ -936,7 +936,7 @@
 
         for (const auto& propertyName : propertyNames) {
             bool excluded = isPropertyNameExcluded(globalObject, propertyName);
-            RETURN_IF_EXCEPTION(scope, false);
+            RETURN_IF_EXCEPTION(scope, { });
             if (excluded)
                 continue;
 
@@ -956,6 +956,7 @@
             RETURN_IF_EXCEPTION(scope, { });
 
             target->putDirectMayBeIndex(globalObject, propertyName, value);
+            RETURN_IF_EXCEPTION(scope, { });
         }
     }
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to