linux/ipc
Stanislav Kinsbursky 2dc958fa2f ipc: set msg back to -EAGAIN if copy wasn't performed
Make sure that msg pointer is set back to error value in case of
MSG_COPY flag is set and desired message to copy wasn't found.  This
garantees that msg is either a error pointer or a copy address.

Otherwise the last message in queue will be freed without unlinking from
the queue (which leads to memory corruption) and the dummy allocated
copy won't be released.

Signed-off-by: Stanislav Kinsbursky <skinsbursky@parallels.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2013-04-02 10:09:01 -07:00
..
compat_mq.c ipc: initialize structure memory to zero for compat functions 2010-10-27 18:03:13 -07:00
compat.c selftests: IPC message queue copy feature test 2013-01-04 16:11:45 -08:00
ipc_sysctl.c ipc: add sysctl to specify desired next object id 2013-01-04 16:11:45 -08:00
ipcns_notifier.c ipc: do not use a negative value to re-enable msgmni automatic recomputing 2008-07-25 10:53:42 -07:00
Makefile Add generic sys_ipc wrapper 2010-03-12 15:52:32 -08:00
mq_sysctl.c mqueue: separate mqueue default value from maximum value 2012-05-31 17:49:31 -07:00
mqueue.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2013-03-28 13:43:46 -07:00
msg.c ipc: set msg back to -EAGAIN if copy wasn't performed 2013-04-02 10:09:01 -07:00
msgutil.c ipc: fix potential oops when src msg > 4k w/ MSG_COPY 2013-03-08 15:05:33 -08:00
namespace.c userns: Require CAP_SYS_ADMIN for most uses of setns. 2012-12-14 16:12:03 -08:00
sem.c userns: Convert ipc to use kuid and kgid where appropriate 2012-09-06 22:17:20 -07:00
shm.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2013-02-26 20:16:07 -08:00
syscall.c ipc: add COMPAT_SHMLBA support 2012-07-30 17:25:20 -07:00
util.c ipc: convert to idr_alloc() 2013-02-27 19:10:19 -08:00
util.h ipc: introduce message queue copy feature 2013-01-04 16:11:45 -08:00