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 <lorenzo@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Lorenzo Colitti 2013-07-04 00:12:40 +09:00 committed by David S. Miller
parent a1bdc45580
commit fbfe80c890

View File

@ -191,7 +191,10 @@ int ping_v6_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
}
release_sock(sk);
return err;
if (err)
return err;
return len;
}
#ifdef CONFIG_PROC_FS