]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
conf: do not log devpts umount2() failure
authorChristian Brauner <christian.brauner@ubuntu.com>
Fri, 15 Feb 2019 22:42:30 +0000 (23:42 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Fri, 15 Feb 2019 22:53:32 +0000 (23:53 +0100)
We're not acting based on the return value so don't log anything.

Fixes: https://discuss.linuxcontainers.org/t/warning-in-the-container-log/4072/2
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/conf.c

index 65011cef39b4efa4958f91e4de144c402a35d34e..cb5730af6588ed8d1f5e154d978ddcc7deb86627 100644 (file)
@@ -1639,11 +1639,7 @@ static int lxc_setup_devpts(struct lxc_conf *conf)
        if (ret < 0 || (size_t)ret >= sizeof(devpts_mntopts))
                return -1;
 
-       ret = umount2("/dev/pts", MNT_DETACH);
-       if (ret < 0)
-               SYSWARN("Failed to unmount old devpts instance");
-       else
-               DEBUG("Unmounted old devpts instance");
+       (void)umount2("/dev/pts", MNT_DETACH);
 
        /* Create mountpoint for devpts instance. */
        ret = mkdir("/dev/pts", 0755);