Ian Kent <ik...@redhat.com> wrote: > +#include <linux/fs.h>
Is that actually needed? > + rki = kmalloc(sizeof(*rki), GFP_KERNEL); > + if (!rki) > + return -ENOMEM; > + > + if (use_ns) { > + tsk = umh_get_init_pid(); > + if (IS_ERR(tsk)) > + return PTR_ERR(tsk); Memory leak of rki. > + /* If running within a container use the container namespace */ > + if (current->nsproxy->net_ns != &init_net) Is that a viable check? Is it possible to have a container that shares networking details? David -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/