jerryscript icon indicating copy to clipboard operation
jerryscript copied to clipboard

Segmentation fault on String.Replace

Open egavrin opened this issue 11 years ago • 1 comments

Version: 17a5dd27bbbadc036d83be0448f9edfa90800147
System:
Linux eg 4.2.0-18-generic #22-Ubuntu SMP Fri Nov 6 18:25:50 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
Test case:
''.replace(/$/g,"a");
Output:

../jerry-bugs/run-test.sh: line 8: 11269 Segmentation fault      ./build/bin/debug.linux/jerry $file

egavrin avatar Nov 24 '15 17:11 egavrin

''.replace(/^/g, "a");

it is not dead code but this code's output is not correct. it is expected 'a' but it returned '' I think this is same issue with this.

idkiller avatar Nov 25 '15 12:11 idkiller