From: Stanislav Kinsbursky Date: Fri, 4 Jan 2013 23:34:47 +0000 (-0800) Subject: ipc: remove forced assignment of selected message X-Git-Tag: v3.8-rc3~16^2~33 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9afdacda0252fc1ddb7907728e878518edbcdfce;p=thirdparty%2Fkernel%2Flinux.git ipc: remove forced assignment of selected message This is a cleanup patch. The assignment is redundant. Signed-off-by: Stanislav Kinsbursky Cc: Serge Hallyn Cc: "Eric W. Biederman" Cc: Pavel Emelyanov Cc: Al Viro Cc: KOSAKI Motohiro Cc: Michael Kerrisk Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/ipc/msg.c b/ipc/msg.c index a71af5a65abf2..2f272fa765956 100644 --- a/ipc/msg.c +++ b/ipc/msg.c @@ -793,12 +793,9 @@ long do_msgrcv(int msqid, long *pmtype, void __user *mtext, msg = walk_msg; if (mode == SEARCH_LESSEQUAL && walk_msg->m_type != 1) { - msg = walk_msg; msgtyp = walk_msg->m_type - 1; - } else { - msg = walk_msg; + } else break; - } } tmp = tmp->next; }