]> git.hungrycats.org Git - linux/commit
[PATCH] remove magic +1 from shm segment count
authorManfred Spraul <manfred@colorfullife.com>
Tue, 24 Aug 2004 04:27:43 +0000 (21:27 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Tue, 24 Aug 2004 04:27:43 +0000 (21:27 -0700)
commitfefd81e1513d6871ffe209a53003c06be6e760da
tree9c0e69575ccb1debce2c73e4f5ac2af0215478f0
parent11c61286f67647491bda3398903f07929e74fe28
[PATCH] remove magic +1 from shm segment count

Michael Kerrisk found a bug in the shm accounting code: sysv shm allows to
create SHMMNI+1 shared memory segments, instead of SHMMNI segments.  The +1
is probably from the first shared anonymous mapping implementation that
used the sysv code to implement shared anon mappings.

The implementation got replaced, it's now the other way around (sysv uses
the shared anon code), but the +1 remained.

Signed-off-by: Manfred Spraul <manfred@colorfullife.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
ipc/shm.c