]> git.neil.brown.name Git - history.git/commit
[PATCH] fix queues_count accounting in mqueue_delete_inode()
authorChris Wright <chrisw@osdl.org>
Tue, 4 May 2004 11:48:34 +0000 (04:48 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Tue, 4 May 2004 11:48:34 +0000 (04:48 -0700)
commit990e3971f2b7850a9cef2853c7f96945ba7fa5e1
treeb4e46aa06cbfa47dbbd97c3cd26679f43bbf30f3
parentdae1a193e4543ebbaceaa2eab56bf3d025097a8d
[PATCH] fix queues_count accounting in mqueue_delete_inode()

During mqueue_get_inode(), it's possible that kmalloc() of the
info->messages array will fail.  This failure mode will cause the
queues_count to be (incorrectly) decremented twice.  This patch uses
info->messages on mqueue_delete_inode() to determine whether the
mqueue was every truly created, and hence proper accounting is needed
on destruction.
ipc/mqueue.c