Skip to content
This repository has been archived by the owner on May 4, 2018. It is now read-only.

windows: Always initialize the uv_process_t #1117

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/win/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -811,6 +811,9 @@ int uv_spawn(uv_loop_t* loop,
PROCESS_INFORMATION info;
DWORD process_flags;

uv_process_init(loop, process);
process->exit_cb = options->exit_cb;

if (options->flags & (UV_PROCESS_SETGID | UV_PROCESS_SETUID)) {
return UV_ENOTSUP;
}
Expand All @@ -827,9 +830,6 @@ int uv_spawn(uv_loop_t* loop,
UV_PROCESS_WINDOWS_HIDE |
UV_PROCESS_WINDOWS_VERBATIM_ARGUMENTS)));

uv_process_init(loop, process);
process->exit_cb = options->exit_cb;

err = uv_utf8_to_utf16_alloc(options->file, &application);
if (err)
goto done;
Expand Down