Add proxy check in ecma_op_object_put_with_receiver (#4411)

JerryScript-DCO-1.0-Signed-off-by: bence gabor kis kisbg@inf.u-szeged.hu
This commit is contained in:
kisbg
2021-01-06 08:44:48 +01:00
committed by GitHub
parent 6279670484
commit 2ac3c08c14
3 changed files with 41 additions and 1 deletions
@@ -1523,6 +1523,15 @@ ecma_op_object_put_with_receiver (ecma_object_t *object_p, /**< the object */
}
}
#if ENABLED (JERRY_BUILTIN_PROXY)
if (create_new_property
&& ecma_is_value_object (receiver)
&& ECMA_OBJECT_IS_PROXY (ecma_get_object_from_value (receiver)))
{
return ecma_op_object_put_apply_receiver (receiver, property_name_p, value, is_throw);
}
#endif /* ENABLED (JERRY_BUILTIN_PROXY) */
if (create_new_property
&& ecma_op_ordinary_object_is_extensible (object_p))
{