From 1a529c3b6a46d312c21acc7d35e4ef897ea24797 Mon Sep 17 00:00:00 2001 From: John Alanbrook Date: Wed, 25 Feb 2026 23:26:26 -0600 Subject: [PATCH] fix gc bug --- model.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/model.c b/model.c index 5e0df95..adb8de8 100644 --- a/model.c +++ b/model.c @@ -538,7 +538,8 @@ JSValue js_model_pack_vertices(JSContext *js, JSValue this_val, int argc, JSValu JS_FRAME(js); JS_ROOT(result, JS_NewObject(js)); - JS_SetPropertyStr(js, result.val, "data", js_new_blob_stoned_copy(js, packed, total_size)); + JSValue blob = js_new_blob_stoned_copy(js, packed, total_size); + JS_SetPropertyStr(js, result.val, "data", blob); JS_SetPropertyStr(js, result.val, "stride", JS_NewInt32(js, stride)); JS_SetPropertyStr(js, result.val, "vertex_count", JS_NewInt32(js, vertex_count)); JS_SetPropertyStr(js, result.val, "skinned", JS_NewBool(js, skinned));