Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

windows: fail uv_spawn() if options.file is NULL

  • Loading branch information
Igor Zinkovsky
Igor Zinkovsky committed Sep 19, 2011
1 parent 37e8bf2 commit ee115bfd8d5f22194736cbc5c172ee1c1de9c4e9
Showing with 7 additions and 2 deletions.
  1. +7 −2 src/win/process.c
@@ -845,14 +845,19 @@ static int duplicate_std_handle(uv_loop_t* loop, DWORD id, HANDLE* dup) {
int uv_spawn(uv_loop_t* loop, uv_process_t* process,
uv_process_options_t options) {
int err = 0, keep_child_stdio_open = 0;
wchar_t* path;
wchar_t* path = NULL;
int size;
BOOL result;
wchar_t* application_path, *application, *arguments, *env, *cwd;
wchar_t* application_path = NULL, *application = NULL, *arguments = NULL, *env = NULL, *cwd = NULL;
HANDLE* child_stdio = process->child_stdio;
STARTUPINFOW startup;
PROCESS_INFORMATION info;

if (!options.file) {
uv_set_error(loop, UV_EINVAL, 0);
return -1;
}

uv_process_init(loop, process);

process->exit_cb = options.exit_cb;

0 comments on commit ee115bf

Please sign in to comment.
You can’t perform that action at this time.