From: David S. Miller Date: Tue, 21 Feb 2012 22:59:19 +0000 (-0500) Subject: ipv4: ping: Fix recvmsg MSG_OOB error handling. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=a5e7424d424f6398a198ead79d99e0a3c2f24ce8;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git ipv4: ping: Fix recvmsg MSG_OOB error handling. Don't return an uninitialized variable as the error, return -EOPNOTSUPP instead. Reported-by: Dave Jones Signed-off-by: David S. Miller --- diff --git a/net/ipv4/ping.c b/net/ipv4/ping.c index aea5a199c37..b072386cee2 100644 --- a/net/ipv4/ping.c +++ b/net/ipv4/ping.c @@ -630,6 +630,7 @@ static int ping_recvmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg, pr_debug("ping_recvmsg(sk=%p,sk->num=%u)\n", isk, isk->inet_num); + err = -EOPNOTSUPP; if (flags & MSG_OOB) goto out;