Date: Sun, 10 Jul 2016 16:10:16 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 210943] Page fault in ip6_setpktopts when syncthing is started with pflog loaded Message-ID: <bug-210943-8-h7zUOZ3ewQ@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-210943-8@https.bugs.freebsd.org/bugzilla/> References: <bug-210943-8@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D210943 Dimitry Andric <dim@FreeBSD.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ae@FreeBSD.org --- Comment #1 from Dimitry Andric <dim@FreeBSD.org> --- Bisection shows this was introduced by r271396 [1]. Specifically, this part that was added: 2572 if (ifp !=3D NULL && ( 2573 ND_IFINFO(ifp)->flags & ND6_IFF_IFDISABLED)) 2574 return (ENETDOWN); The problem is that ND_IFINFO(ifp) dereferences ifp->if_afdata[AF_INET6] unconditionally, so if that is NULL, a page fault occurs. Maybe a good fix is just the following? Index: sys/netinet6/ip6_output.c =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- sys/netinet6/ip6_output.c (revision 271396) +++ sys/netinet6/ip6_output.c (working copy) @@ -2569,7 +2569,7 @@ if (ifp =3D=3D NULL) return (ENXIO); } - if (ifp !=3D NULL && ( + if (ifp !=3D NULL && ifp->if_afdata[AF_INET6] !=3D NULL && ( ND_IFINFO(ifp)->flags & ND6_IFF_IFDISABLED)) return (ENETDOWN); [1] https://svnweb.freebsd.org/base?view=3Drevision&revision=3D271396 --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-210943-8-h7zUOZ3ewQ>