From 87aee2b3f73f0efd2cb89fa2d460fd7c6db5f037 Mon Sep 17 00:00:00 2001 From: Brendan Hansen Date: Thu, 26 May 2022 12:19:57 -0500 Subject: [PATCH] bugfix with windows process spawn --- src/onyx_runtime.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/onyx_runtime.c b/src/onyx_runtime.c index 804dfc97..412e6be8 100644 --- a/src/onyx_runtime.c +++ b/src/onyx_runtime.c @@ -635,8 +635,9 @@ ONYX_DEF(__process_spawn, (WASM_I32, WASM_I32, WASM_I32, WASM_I32, WASM_I32, WAS char *arg_str = ONYX_PTR(*(i32 *) (array_loc + i * 2 * POINTER_SIZE)); i32 arg_len = *(i32 *) (array_loc + i * 2 * POINTER_SIZE + 4); - strncat(cmdLine, " ", 2047); + strncat(cmdLine, " \"", 2047); strncat(cmdLine, arg_str, arg_len); + strncat(cmdLine, "\"", 2047); } STARTUPINFOA startup; -- 2.25.1