Fix value release in ecma_op_is_concat_spreadable (#3346)
Fixes #3356 Fixes #3361 JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
This commit is contained in:
committed by
Robert Fancsik
parent
0c6b306429
commit
b7508c636c
@@ -2571,7 +2571,9 @@ ecma_op_is_concat_spreadable (ecma_value_t arg) /**< argument */
|
||||
|
||||
if (!ecma_is_value_undefined (spreadable))
|
||||
{
|
||||
return ecma_make_boolean_value (ecma_op_to_boolean (spreadable));
|
||||
const bool to_bool = ecma_op_to_boolean (spreadable);
|
||||
ecma_free_value (spreadable);
|
||||
return ecma_make_boolean_value (to_bool);
|
||||
}
|
||||
|
||||
return (ecma_make_boolean_value (ecma_is_value_array (arg)));
|
||||
|
||||
Reference in New Issue
Block a user