]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
conf: s/pipe()/pipe2()/g
authorChristian Brauner <christian.brauner@ubuntu.com>
Sun, 29 Jul 2018 21:02:14 +0000 (23:02 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Mon, 10 Dec 2018 15:01:11 +0000 (16:01 +0100)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/conf.c

index 0cd686861cc5093a91bb8672b20b1e09dcee29c5..6e53aa6adcc23cb329116a47976ea4dc685e44bd 100644 (file)
@@ -3999,7 +3999,7 @@ int userns_exec_1(struct lxc_conf *conf, int (*fn)(void *), void *data,
        if (!idmap)
                return -1;
 
-       ret = pipe(p);
+       ret = pipe2(p, O_CLOEXEC);
        if (ret < 0) {
                SYSERROR("Failed to create pipe");
                return -1;
@@ -4081,7 +4081,7 @@ int userns_exec_full(struct lxc_conf *conf, int (*fn)(void *), void *data,
        if (!conf)
                return -EINVAL;
 
-       ret = pipe(p);
+       ret = pipe2(p, O_CLOEXEC);
        if (ret < 0) {
                SYSERROR("opening pipe");
                return -1;