Skip to content

Commit

Permalink
Fix crash while buildStacktrace
Browse files Browse the repository at this point in the history
Signed-off-by: Seonghyun Kim <[email protected]>
  • Loading branch information
ksh8281 committed Oct 2, 2024
1 parent 7365c2a commit b3f5527
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/runtime/SandBox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ void StackTraceData::buildStackTrace(Context* context, StringBuilder& builder)
builder.appendString(String::fromDouble(loc.column));

String* src = block->m_codeBlock->script()->sourceCode();
if (src->length()) {
if (src->length() && loc.index != SIZE_MAX) {
const size_t preLineMax = 40;
const size_t afterLineMax = 40;

Expand Down

0 comments on commit b3f5527

Please sign in to comment.