Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/sys/netinet/ip_input.c,v rcsdiff: /ftp/cvs/cvsroot/src/sys/netinet/ip_input.c,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.250.4.1 retrieving revision 1.253 diff -u -p -r1.250.4.1 -r1.253 --- src/sys/netinet/ip_input.c 2007/08/16 11:03:46 1.250.4.1 +++ src/sys/netinet/ip_input.c 2007/09/11 14:18:09 1.253 @@ -1,4 +1,4 @@ -/* $NetBSD: ip_input.c,v 1.250.4.1 2007/08/16 11:03:46 jmcneill Exp $ */ +/* $NetBSD: ip_input.c,v 1.253 2007/09/11 14:18:09 degroote Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -98,7 +98,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ip_input.c,v 1.250.4.1 2007/08/16 11:03:46 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ip_input.c,v 1.253 2007/09/11 14:18:09 degroote Exp $"); #include "opt_inet.h" #include "opt_gateway.h" @@ -1013,7 +1013,6 @@ found: /* XXX error stat??? */ error = EINVAL; DPRINTF(("ip_input: no SP, packet discarded\n"));/*XXX*/ - goto bad; } splx(s); if (error) @@ -2079,8 +2078,11 @@ ip_savecontrol(struct inpcb *inp, struct if (inp->inp_flags & INP_RECVIF) { struct sockaddr_dl sdl; - sockaddr_dl_init(&sdl, (m->m_pkthdr.rcvif != NULL) ? - m->m_pkthdr.rcvif->if_index : 0, 0, NULL, 0, NULL, 0); + sockaddr_dl_init(&sdl, sizeof(sdl), + (m->m_pkthdr.rcvif != NULL) + ? m->m_pkthdr.rcvif->if_index + : 0, + 0, NULL, 0, NULL, 0); *mp = sbcreatecontrol(&sdl, sdl.sdl_len, IP_RECVIF, IPPROTO_IP); if (*mp) mp = &(*mp)->m_next;