Module Name: src Committed By: is Date: Fri Apr 29 11:46:17 UTC 2016
Modified Files: src/sys/netinet6: nd6_nbr.c Log Message: Let non-neighbor NS/NA debug error message include useful information. To generate a diff of this commit: cvs rdiff -u -r1.116 -r1.117 src/sys/netinet6/nd6_nbr.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/netinet6/nd6_nbr.c diff -u src/sys/netinet6/nd6_nbr.c:1.116 src/sys/netinet6/nd6_nbr.c:1.117 --- src/sys/netinet6/nd6_nbr.c:1.116 Mon Apr 11 01:16:20 2016 +++ src/sys/netinet6/nd6_nbr.c Fri Apr 29 11:46:17 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: nd6_nbr.c,v 1.116 2016/04/11 01:16:20 ozaki-r Exp $ */ +/* $NetBSD: nd6_nbr.c,v 1.117 2016/04/29 11:46:17 is Exp $ */ /* $KAME: nd6_nbr.c,v 1.61 2001/02/10 16:06:14 jinmei Exp $ */ /* @@ -31,7 +31,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: nd6_nbr.c,v 1.116 2016/04/11 01:16:20 ozaki-r Exp $"); +__KERNEL_RCSID(0, "$NetBSD: nd6_nbr.c,v 1.117 2016/04/29 11:46:17 is Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -149,7 +149,9 @@ nd6_ns_input(struct mbuf *m, int off, in */ sockaddr_in6_init(&ssin6, &saddr6, 0, 0, 0); if (nd6_is_addr_neighbor(&ssin6, ifp) == 0) { - nd6log(LOG_INFO, "NS packet from non-neighbor\n"); + nd6log(LOG_INFO, + "NS packet from non-neighbor %s on %s\n", + ip6_sprintf(&saddr6), if_name(ifp)); goto bad; } } @@ -625,7 +627,8 @@ nd6_na_input(struct mbuf *m, int off, in */ sockaddr_in6_init(&ssin6, &saddr6, 0, 0, 0); if (nd6_is_addr_neighbor(&ssin6, ifp) == 0) { - nd6log(LOG_INFO, "ND packet from non-neighbor\n"); + nd6log(LOG_INFO, "ND packet from non-neighbor %s on %s\n", + ip6_sprintf(&saddr6), if_name(ifp)); goto bad; }