]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
lxc-attach: fix access permissions of /proc/$pid/ns
authorCedric Le Goater <clg@fr.ibm.com>
Mon, 4 Apr 2011 15:05:47 +0000 (17:05 +0200)
committerDaniel Lezcano <dlezcano@fr.ibm.com>
Wed, 6 Apr 2011 11:37:21 +0000 (13:37 +0200)
Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Signed-off-by: Daniel Lezcano <dlezcano@fr.ibm.com>
src/lxc/namespace.c

index 27b53b0bf5e2b97c25566ab4ec47207476ef4da7..8263fe79a41dfe40a0b1b6bc157aec75eba81d94 100644 (file)
@@ -91,7 +91,7 @@ int lxc_attach(pid_t pid)
        int i;
 
        sprintf(path, "/proc/%d/ns", pid);
-       if (access(path, R_OK)) {
+       if (access(path, X_OK)) {
                ERROR("Does this kernel version support 'attach' ?");
                return -1;
        }