From a63534e6e6fa351d1c51b1d7cd14f916af3f835a Mon Sep 17 00:00:00 2001 From: "H. Peter Anvin" Date: Fri, 11 Dec 2009 16:05:48 -0800 Subject: [PATCH] recvfrom: fix the type of the fallthrough case If we can't figure out the source address, we have the "fall on our face" version of myrecvfrom(); make sure its prototype matches. This handles building on machines where sockaddr_t != int and yet there is no way to get the source address. This apparently affects at least one version of Solaris. Reported-by: Georg Schwarz Signed-off-by: H. Peter Anvin --- tftpd/recvfrom.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tftpd/recvfrom.c b/tftpd/recvfrom.c index 389ba82..3ee5642 100644 --- a/tftpd/recvfrom.c +++ b/tftpd/recvfrom.c @@ -245,7 +245,8 @@ myrecvfrom(int s, void *buf, int len, unsigned int flags, int myrecvfrom(int s, void *buf, int len, unsigned int flags, - struct sockaddr *from, int *fromlen, union sock_addr *myaddr) + struct sockaddr *from, socklen_t * fromlen, + union sock_addr *myaddr) { /* There is no way we can get the local address, fudge it */