icmp6-util: port to recvmsg_safe()

Split out of #15457, let's see if this is the culprit of the CI failure.
This commit is contained in:
Lennart Poettering
2020-04-24 07:41:32 +02:00
committed by Zbigniew Jędrzejewski-Szmek
parent 84b5d3e532
commit 2adfd1bda1
+2 -2
View File
@@ -167,9 +167,9 @@ int icmp6_receive(int fd, void *buffer, size_t size, struct in6_addr *dst,
iov = IOVEC_MAKE(buffer, size);
len = recvmsg(fd, &msg, MSG_DONTWAIT);
len = recvmsg_safe(fd, &msg, MSG_DONTWAIT);
if (len < 0)
return -errno;
return (int) len;
if ((size_t) len != size)
return -EINVAL;