fix gc error
This commit is contained in:
@@ -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);
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user