Index: bpf.c =================================================================== RCS file: /usr/ncvs/src/sys/net/bpf.c,v retrieving revision 1.166 diff -u -r1.166 bpf.c --- bpf.c 2 Jun 2006 19:59:32 -0000 1.166 +++ bpf.c 4 Jun 2006 12:20:52 -0000 @@ -1784,6 +1784,7 @@ SYSINIT(bpfdev,SI_SUB_DRIVERS,SI_ORDER_MIDDLE,bpf_drvinit,NULL) #else /* !DEV_BPF && !NETGRAPH_BPF */ +static struct bpf_if bpf_null; /* * NOP stubs to allow bpf-using drivers to load and function. * @@ -1820,6 +1821,8 @@ struct ifnet *ifp; u_int dlt, hdrlen; { + + bpfattach2(ifp, dlt, hdrlen, &ifp->if_bpf); } void @@ -1828,6 +1831,8 @@ u_int dlt, hdrlen; struct bpf_if **driverp; { + + *driverp = &bpf_null; } void Index: bpf.h =================================================================== RCS file: /usr/ncvs/src/sys/net/bpf.h,v retrieving revision 1.44 diff -u -r1.44 bpf.h --- bpf.h 3 Jun 2006 18:48:14 -0000 1.44 +++ bpf.h 4 Jun 2006 12:14:52 -0000 @@ -630,9 +630,7 @@ bpf_peers_present(struct bpf_if *bpf) { - if (bpf && !LIST_EMPTY(&bpf->bif_dlist)) - return (1); - return (0); + return (!LIST_EMPTY(&bpf->bif_dlist)); } #define BPF_TAP(_ifp,_pkt,_pktlen) do { \