fix gc error

This commit is contained in:
2026-02-21 03:07:38 -06:00
parent 5975298ec4
commit 6bdd375dbb
10 changed files with 259 additions and 131 deletions

View File

@@ -325,7 +325,8 @@ JSC_CCALL(joystick_get_power_info,
JS_FRAME(js);
JS_LOCAL(result, JS_NewObject(js));
JS_SetPropertyStr(js, result, "state", JS_NewString(js, state_str));
JSValue _state = JS_NewString(js, state_str);
JS_SetPropertyStr(js, result, "state", _state);
JS_SetPropertyStr(js, result, "percent", JS_NewInt32(js, percent));
JS_RETURN(result);
)