Remove string copy
Changed 'ecma_copy_or_ref_ecma_string' to 'ecma_ref_ecma_string'. It does not copy the string if the maximum number of reference counter is reached, but bails out with an error like the 'ecma_ref_object' function does. JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
This commit is contained in:
@@ -123,7 +123,7 @@ ecma_new_standard_error_with_message (ecma_standard_error_t error_type, /**< nat
|
||||
ECMA_PROPERTY_CONFIGURABLE_WRITABLE);
|
||||
|
||||
ecma_set_named_data_property_value (prop_p,
|
||||
ecma_make_string_value (ecma_copy_or_ref_ecma_string (message_string_p)));
|
||||
ecma_make_string_value (ecma_ref_ecma_string (message_string_p)));
|
||||
ecma_deref_ecma_string (message_magic_string_p);
|
||||
|
||||
return new_error_obj_p;
|
||||
|
||||
Reference in New Issue
Block a user