|
|
@@ -427,7 +427,8 @@ void cmd_line_run_sync(Cmd_Line cmd_line)
|
|
|
#ifndef _WIN32
|
|
|
pid_wait(cmd_line_run_async(cmd_line));
|
|
|
#else
|
|
|
- intptr_t status = _spawnvp(_P_WAIT, cmd_line.line.elems[0], (char * const*) cmd_line.line.elems);
|
|
|
+ Cstr_Array args = cstr_array_append(cmd_line.line, NULL);
|
|
|
+ intptr_t status = _spawnvp(_P_WAIT, args.elems[0], (char * const*) args.elems);
|
|
|
if (status < 0) {
|
|
|
PANIC("could not start child process: %s", strerror(errno));
|
|
|
}
|