mirror of
https://git.proxmox.com/git/mirror_lxc
synced 2025-08-08 08:16:20 +00:00
coverity: Check return value of fcntl in lxc_popen
Signed-off-by: Stéphane Graber <stgraber@ubuntu.com> Acked-by: Serge E. Hallyn <serge.hallyn@ubuntu.com>
This commit is contained in:
parent
e7de366c67
commit
57d2be5493
@ -642,7 +642,10 @@ extern struct lxc_popen_FILE *lxc_popen(const char *command)
|
|||||||
* But it must not be marked close-on-exec.
|
* But it must not be marked close-on-exec.
|
||||||
* Undo the effects.
|
* Undo the effects.
|
||||||
*/
|
*/
|
||||||
fcntl(child_end, F_SETFD, 0);
|
if (fcntl(child_end, F_SETFD, 0) != 0) {
|
||||||
|
SYSERROR("Failed to remove FD_CLOEXEC from fd.");
|
||||||
|
exit(127);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user