On 09/04, Andrew Vagin wrote:
>
> The kernel doesn't check pid on a negative values, so if
> you would try to write -2 in /proc/sys/kernel/ns_last_pid,
> you will get a kernel panic.
>
> In this case the next pid is -1, and alloc_pidmap will try to access
> to a nonexistent pidmap.
>
> map = &pid_n
The kernel doesn't check pid on a negative values, so if
you would try to write -2 in /proc/sys/kernel/ns_last_pid,
you will get a kernel panic.
In this case the next pid is -1, and alloc_pidmap will try to access
to a nonexistent pidmap.
map = &pid_ns->pidmap[pid/BITS_PER_PAGE];
Cc: Andrew Mort
2 matches
Mail list logo