summaryrefslogtreecommitdiff
path: root/ipc
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-03-17 18:27:39 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-03-17 18:27:39 (GMT)
commite40bffaeaed9c5a26c3e5c961c3dee72c1b46558 (patch)
tree619aa9f481fbddb267dcd6f1ef454c846bdfc983 /ipc
parentcc43adab9a5b7f3b7c320ded7dbd771aca421f1a (diff)
parentdcb99fd9b08cfe1afe426af4d8d3cbc429190f15 (diff)
downloadlinux-e40bffaeaed9c5a26c3e5c961c3dee72c1b46558.tar.xz
Merge 3.14-rc7 into staging-next
This resolves a merge issue with drivers/staging/cxt1e1/linux.c that was fixed in a report from Stephen Rothwell Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'ipc')
-rw-r--r--ipc/msg.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ipc/msg.c b/ipc/msg.c
index 245db11..6498531 100644
--- a/ipc/msg.c
+++ b/ipc/msg.c
@@ -901,6 +901,8 @@ long do_msgrcv(int msqid, void __user *buf, size_t bufsz, long msgtyp, int msgfl
return -EINVAL;
if (msgflg & MSG_COPY) {
+ if ((msgflg & MSG_EXCEPT) || !(msgflg & IPC_NOWAIT))
+ return -EINVAL;
copy = prepare_copy(buf, min_t(size_t, bufsz, ns->msg_ctlmax));
if (IS_ERR(copy))
return PTR_ERR(copy);