Lines Matching defs:options

109   int options;
126 options = 0;
130 options = WNOHANG;
134 pid = waitpid(process->pid, &status, options);
183 * Used for initializing stdio streams like options.stdin_stream. Returns
277 static void uv__process_child_init(const uv_process_options_t* options,
307 if (options->flags & UV_PROCESS_DETACHED)
372 if (options->cwd != NULL && chdir(options->cwd))
375 if (options->flags & (UV_PROCESS_SETUID | UV_PROCESS_SETGID)) {
386 if ((options->flags & UV_PROCESS_SETGID) && setgid(options->gid))
389 if ((options->flags & UV_PROCESS_SETUID) && setuid(options->uid))
392 if (options->env != NULL)
393 environ = options->env;
401 execvpe(options->file, options->args, environ);
403 execvp(options->file, options->args);
462 const uv_process_options_t* options) {
473 if (options->flags & (UV_PROCESS_SETUID | UV_PROCESS_SETGID)) {
496 if (options->flags & UV_PROCESS_DETACHED) {
534 const uv_process_options_t* options,
549 if (options->cwd != NULL) {
555 err = posix_spawn_fncs->file_actions.addchdir_np(actions, options->cwd);
668 static int uv__spawn_resolve_and_spawn(const uv_process_options_t* options,
685 if (options->file == NULL)
689 * by options->env */
691 if (options->env != NULL)
692 env = options->env;
694 /* If options->file contains a slash, posix_spawn/posix_spawnp should behave
698 if (strchr(options->file, '/') != NULL) {
700 err = posix_spawn(pid, options->file, actions, attrs, options->args, env);
717 k = strnlen(options->file, NAME_MAX + 1);
738 memcpy(b + (z - p) + (z > p), options->file, k + 1);
744 err = posix_spawn(pid, b, actions, attrs, options->args, env);
769 const uv_process_options_t* options,
778 err = uv__spawn_set_posix_spawn_attrs(&attrs, posix_spawn_fncs, options);
785 options,
793 /* Try to spawn options->file resolving in the provided environment
795 err = uv__spawn_resolve_and_spawn(options, &attrs, &actions, pid);
809 static int uv__spawn_and_init_child_fork(const uv_process_options_t* options,
835 uv__process_child_init(options, stdio_count, pipes, error_fd);
852 const uv_process_options_t* options,
878 err = uv__spawn_and_init_child_posix_spawn(options,
919 err = uv__spawn_and_init_child_fork(options, stdio_count, pipes, signal_pipe[1], pid);
958 const uv_process_options_t* options) {
971 assert(options->file != NULL);
972 assert(!(options->flags & ~(UV_PROCESS_DETACHED |
985 stdio_count = options->stdio_count;
1002 for (i = 0; i < options->stdio_count; i++) {
1003 err = uv__process_init_stdio(options->stdio + i, pipes[i]);
1013 exec_errorno = uv__spawn_and_init_child(loop, options, stdio_count, pipes, &pid);
1044 process->exit_cb = options->exit_cb;
1049 for (i = 0; i < options->stdio_count; i++) {
1050 err = uv__process_open_stream(options->stdio + i, pipes[i]);
1055 uv__process_close_stream(options->stdio + i);
1068 if (i < options->stdio_count)
1069 if (options->stdio[i].flags & (UV_INHERIT_FD | UV_INHERIT_STREAM))