]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - kernel/sysctl.c
pid namespaces: changes to show virtual ids to user
[linux-2.6-omap-h63xx.git] / kernel / sysctl.c
index 067554bda8b79ba3954f2dc653dfa4f25f98f09c..3b4efbe2644572a32576b1a591f003e9869699f0 100644 (file)
@@ -1888,7 +1888,7 @@ int proc_dointvec_bset(struct ctl_table *table, int write, struct file *filp,
                return -EPERM;
        }
 
-       op = is_init(current) ? OP_SET : OP_AND;
+       op = is_global_init(current) ? OP_SET : OP_AND;
        return do_proc_dointvec(table,write,filp,buffer,lenp,ppos,
                                do_proc_dointvec_bset_conv,&op);
 }
@@ -2278,7 +2278,7 @@ static int proc_do_cad_pid(struct ctl_table *table, int write, struct file *filp
        pid_t tmp;
        int r;
 
-       tmp = pid_nr(cad_pid);
+       tmp = pid_nr_ns(cad_pid, current->nsproxy->pid_ns);
 
        r = __do_proc_dointvec(&tmp, table, write, filp, buffer,
                               lenp, ppos, NULL, NULL);