FreeBSD/sys/net/bpf.c
/*
 * Free buffers currently in use by a descriptor.
 * Called on close.
 */
Free buffers currently in use by a descriptor.
Called on close.
Free buffers currently in use by a descriptor . Called on close .
static void
bpf_freed(struct bpf_d *d)
{
	bpf_free(d);
	if (d->bd_rfilter != NULL) {
		free((caddr_t)d->bd_rfilter, M_BPF);
#ifdef BPF_JITTER
		if (d->bd_bfilter != NULL)
			bpf_destroy_jit_filter(d->bd_bfilter);
#endif
	}
	if (d->bd_wfilter != NULL)
		free((caddr_t)d->bd_wfilter, M_BPF);
	mtx_destroy(&d->bd_lock);
}
static void bpf_freed ( struct bpf_d * d ) { bpf_free ( d ) ; if ( d -> bd_rfilter != NULL ) { free ( ( caddr_t ) d -> bd_rfilter , M_BPF ) ; #ifdef BPF_JITTER if ( d -> bd_bfilter != NULL ) bpf_destroy_jit_filter ( d -> bd_bfilter ) ; #endif } if ( d -> bd_wfilter != NULL ) free ( ( caddr_t ) d -> bd_wfilter , M_BPF ) ; mtx_destroy ( & d -> bd_lock ) ; }
Free buffers currently in use by a descriptor.
Free buffers currently in use by a descriptor .
/*
	 * We don't need to lock out interrupts since this descriptor has
	 * been detached from its interface and it yet hasn't been marked
	 * free.
	 */