Skip to content

Commit

Permalink
Fix js_string_pad() mem leak
Browse files Browse the repository at this point in the history
  • Loading branch information
xeioex committed May 17, 2024
1 parent d378a9f commit cff5440
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion quickjs.c
Original file line number Diff line number Diff line change
Expand Up @@ -42457,7 +42457,7 @@ static JSValue js_string_pad(JSContext *ctx, JSValueConst this_val,
}
if (n > JS_STRING_LEN_MAX) {
JS_ThrowRangeError(ctx, "invalid string length");
goto fail2;
goto fail3;
}
if (string_buffer_init(ctx, b, n))
goto fail3;
Expand Down

0 comments on commit cff5440

Please sign in to comment.