process: close process pipes safely
Use `uv__close__nocheckstdio` instead of `close`. PR-URL: https://github.com/libuv/libuv/pull/798 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Saúl Ibarra Corretgé <saghul@gmail.com>
This commit is contained in:
parent
6ae622b0a1
commit
643c9e9c32
@ -530,9 +530,9 @@ error:
|
||||
if (options->stdio[i].flags & (UV_INHERIT_FD | UV_INHERIT_STREAM))
|
||||
continue;
|
||||
if (pipes[i][0] != -1)
|
||||
close(pipes[i][0]);
|
||||
uv__close_nocheckstdio(pipes[i][0]);
|
||||
if (pipes[i][1] != -1)
|
||||
close(pipes[i][1]);
|
||||
uv__close_nocheckstdio(pipes[i][1]);
|
||||
}
|
||||
uv__free(pipes);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user