]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
conf: apply /proc/sys and /proc/<pid>/ parameters
authorChristian Brauner <christian.brauner@ubuntu.com>
Thu, 4 Nov 2021 10:26:00 +0000 (11:26 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Thu, 4 Nov 2021 10:26:43 +0000 (11:26 +0100)
When porting to the new list type we added an accidental ! when checking
whether the list is empty.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/conf.c

index 8e068b8ac85ddcbeb44074ed101d5446e78470f0..0885b592174754f8f35dedb845ee2b8f486acdcb 100644 (file)
@@ -3288,7 +3288,7 @@ int setup_sysctl_parameters(struct lxc_conf *conf)
        char filename[PATH_MAX] = {0};
        struct lxc_sysctl *sysctl, *nsysctl;
 
-       if (!list_empty(&conf->sysctls))
+       if (list_empty(&conf->sysctls))
                return 0;
 
        list_for_each_entry_safe(sysctl, nsysctl, &conf->sysctls, head) {
@@ -3317,7 +3317,7 @@ int setup_proc_filesystem(struct lxc_conf *conf, pid_t pid)
        char filename[PATH_MAX] = {0};
        struct lxc_proc *proc;
 
-       if (!list_empty(&conf->procs))
+       if (list_empty(&conf->procs))
                return 0;
 
        list_for_each_entry(proc, &conf->procs, head) {