chakra-core / chakra-core/ChakraCore
Segmentation fault in libc.so.6 ispunct at ctype.c
- Dominant language
- JavaScript
- Stars
- 9.3k
- Forks
- 1.2k
- PR merge metrics
- No merged PRs in 30d
Description
Segmentation fault in libc.so.6 ispunct at ctype.c.
ubuntu 18.04.3
chakra (fd545b428de1a62e3de11962f76699a117bfc4df)
test.js
```javascript
eval(String.fromCodePoint(654321))
```
DebugInfo
```
* thread #1, name = 'ch', stop reason = signal SIGSEGV: address access protected (fault address: 0x7ffff72e94a2)
frame #0: 0x00007ffff703b58e libc.so.6`ispunct(c=654321) at ctype.c:33
(lldb) bt
* thread #1, name = 'ch', stop reason = signal SIGSEGV: address access protected (fault address: 0x7ffff72e94a2)
* frame #0: 0x00007ffff703b58e libc.so.6`ispunct(c=654321) at ctype.c:33
frame #1: 0x000055555676474a ch`PlatformAgnostic::UnicodeText::GetGeneralCategoryClass(ch=654321) at UnicodeText.cpp:163
frame #2: 0x000055555676acb8 ch`Js::CharClassifier::GetBigCharTypeES6(ch=654321, instance=0x00007ffff7f89030) at CharClassifier.cpp:259
frame #3: 0x000055555676ba69 ch`Js::CharClassifier::GetCharType(this=0x00007ffff7f89030, ch=654321) const at CharClassifier.cpp:658
frame #4: 0x000055555687359b ch`Scanner >::ScanCore(this=0x00007fffffff8408, identifyKwds=true) at Scan.cpp:1674
frame #5: 0x000055555687310a ch`Scanner >::Scan(this=0x00007fffffff8408) at Scan.cpp:1567
frame #6: 0x00005555567777a9 ch`Parser::Parse(this=0x00007fffffff8308, pszSrc="������", offset=0, length=6, charOffset=0, isUtf8=false, grfscr=7218, lineNumber=0, nextFunctionId=0x00007ffff7f43084, pse=0x00007fffffff8ee0) at Parse.cpp:11889
frame #7: 0x0000555556777010 ch`Parser::ParseSourceInternal(this=0x00007fffffff8308, parseTree=0x00007fffffff82f8, pszSrc="������", offsetInBytes=0, encodedCharCount=6, offsetInChars=0, isUtf8=false, grfscr=7218, pse=0x00007fffffff8ee0, nextFunctionId=0x00007ffff7f43084, lineNumber=0, sourceContextInfo=0x00007ffff7f43080) at Parse.cpp:510
frame #8: 0x000055555678b977 ch`Parser::ParseCesu8Source(this=0x00007fffffff8308, parseTree=0x00007fffffff82f8, pSrc="������", length=6, grfsrc=7218, pse=0x00007fffffff8ee0, nextFunctionId=0x00007ffff7f43084, sourceContextInfo=0x00007ffff7f43080) at Parse.cpp:12317
frame #9: 0x000055555623c045 ch`Js::GlobalObject::DefaultEvalHelper(scriptContext=0x0000555558280518, source=u"", sourceLength=2, moduleID=0, grfscr=7218, pszTitle=u"eval code", registerDocument=YES, isIndirect=NO, strictMode=NO) at GlobalObject.cpp:875
frame #10: 0x000055555623d8a6 ch`Js::GlobalObject::VEval(library=0x00007ffff7f58000, environment=0x00005555579167f0, moduleID=0, strictMode=false, isIndirect=false, args=0x00007fffffff91f8, isLibraryCode=false, registerDocument=true, additionalGrfscr=0, debugEvalScriptContext=0x0000000000000000) at GlobalObject.cpp:609
frame #11: 0x000055555623d41f ch`Js::GlobalObject::EntryEvalHelper(scriptContext=0x0000555558280518, function=0x00007ffff7f262c0, args=0x00007fffffff91f8) at GlobalObject.cpp:519
frame #12: 0x000055555623e158 ch`Js::GlobalObject::EntryEval(function=0x00007ffff7f262c0, callInfo=(Count = 2, Flags = 24, unused = 0)) at GlobalObject.cpp:549
frame #13: 0x00005555565f538e ch`amd64_CallFunction at JavascriptFunctionA.S:100
```
Contributor guide
Assessment
This issue has not been assessed yet.