From c5379dc453fbc213564ace21d04dabf5750e207c Mon Sep 17 00:00:00 2001 From: Stanislav Kinsbursky Date: Thu, 25 Oct 2012 12:15:17 +1100 Subject: [PATCH] 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 --- ipc/msg.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ipc/msg.c b/ipc/msg.c index a71af5a65abf..2f272fa76595 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; } -- 2.39.5