net: ipv6: fix wrong ping_v6_sendmsg return value
Subsystems (2)
PATCH 1/1 net: ipv6: fix wrong ping_v6_sendmsg return value
ping_v6_sendmsg currently returns 0 on success. It should return the number of bytes written instead.
Signed-off-by Lorenzo Colitti <[email protected]>
--- net/ipv6/ping.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
net/ipv6/ping.c +4 -1
@@ -189,7 +189,10 @@ int ping_v6_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg, len); } -return err; +if (err) +return err; + +return len; }#ifdef CONFIG_PROC_FS
Signature · 1 line
1.8.3
From: Lorenzo Colitti <[email protected]>
Date: Thu, 4 Jul 2013 00:12:40 +0900
Quoted 4 lines
ping_v6_sendmsgcurrently returns 0 on success. It should return the number of bytes written instead.Signed-off-by Lorenzo Colitti <[email protected]>
Applied.