diff --git a/sysdep/bsd/krt-sock.c b/sysdep/bsd/krt-sock.c index 256c4ed0..47f5cf59 100644 --- a/sysdep/bsd/krt-sock.c +++ b/sysdep/bsd/krt-sock.c @@ -190,6 +190,10 @@ static inline void sockaddr_fill_dl(struct sockaddr_dl *sa, struct iface *ifa) { uint len = OFFSETOF(struct sockaddr_dl, sdl_data); + + /* Workaround for FreeBSD 13.0 */ + len = MAX(len, sizeof(struct sockaddr)); + memset(sa, 0, len); sa->sdl_len = len; sa->sdl_family = AF_LINK;