mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 18:28:25 +00:00
Fix too small control array in tftp code on BSD and SOLARIS
This causes tftp to fail on some BSD versions, for sure. It works by chance on others. https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=241068
This commit is contained in:
@@ -68,9 +68,11 @@ void tftp_request(struct listener *listen, time_t now)
|
||||
#if defined(HAVE_LINUX_NETWORK)
|
||||
char control[CMSG_SPACE(sizeof(struct in_pktinfo))];
|
||||
#elif defined(HAVE_SOLARIS_NETWORK)
|
||||
char control[CMSG_SPACE(sizeof(unsigned int))];
|
||||
char control[CMSG_SPACE(sizeof(struct in_addr)) +
|
||||
CMSG_SPACE(sizeof(unsigned int))];
|
||||
#elif defined(IP_RECVDSTADDR) && defined(IP_RECVIF)
|
||||
char control[CMSG_SPACE(sizeof(struct sockaddr_dl))];
|
||||
char control[CMSG_SPACE(sizeof(struct in_addr)) +
|
||||
CMSG_SPACE(sizeof(struct sockaddr_dl))];
|
||||
#endif
|
||||
} control_u;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user