mirror of
https://github.com/freebsd/freebsd-src
synced 2024-09-06 17:18:32 +00:00
Correctly test return value of pipe(2)
CID: 1393351
This commit is contained in:
parent
a9063ba1d7
commit
5a43dca273
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=335001
|
@ -58,7 +58,8 @@ start_pr(char *file1, char *file2)
|
|||
signal(SIGPIPE, SIG_IGN);
|
||||
fflush(stdout);
|
||||
rewind(stdout);
|
||||
pipe(pfd);
|
||||
if (pipe(pfd) == -1)
|
||||
err(2, "pipe");
|
||||
switch ((pid = pdfork(&pr_pd, PD_CLOEXEC))) {
|
||||
case -1:
|
||||
status |= 2;
|
||||
|
|
Loading…
Reference in a new issue