From: Fabrice Bellard Date: Sat, 21 Nov 2026 11:28:15 +0000 (+0100) Subject: added missing add_arg() error check X-Git-Url: https://git.kaiwu.me/http/ngx_http_access_module.html?a=commitdiff_plain;h=64049e7262c9762c8a158f409235f7fb4a74eebc;p=quickjs.git added missing add_arg() error check --- diff --git a/quickjs.c b/quickjs.c index 03af563..0baef2a 100644 --- a/quickjs.c +++ b/quickjs.c @@ -37916,6 +37916,8 @@ static __exception int js_parse_function_decl2(JSParseState *s, } else { /* unnamed arg for destructuring */ idx = add_arg(ctx, fd, JS_ATOM_NULL); + if (idx < 0) + goto fail; emit_op(s, OP_get_arg); emit_u16(s, idx); }