From ea0e76a28d1b70b4dbc7d704f3a6e3ec70c22a16 Mon Sep 17 00:00:00 2001 From: Ruslan Ermilov Date: Wed, 13 Dec 2006 06:27:20 +0000 Subject: [PATCH] - Fix prototype of bpf_filter(). - Document what passing it a zero buflen argument means. --- share/man/man9/bpf.9 | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/share/man/man9/bpf.9 b/share/man/man9/bpf.9 index c7c4b1d6c3cb..5a3ac07ad270 100644 --- a/share/man/man9/bpf.9 +++ b/share/man/man9/bpf.9 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 19, 2004 +.Dd December 13, 2006 .Dt BPF 9 .Os .\" @@ -51,7 +51,7 @@ .Fn bpf_mtap2 "struct bpf_if *bp" "void *data" "u_int dlen" "struct mbuf *m" .Ft u_int .Fo bpf_filter -.Fa "const struct bpf_insn *pc " "u_char *pkt" "u_int *wirelen" "u_int *buflen" +.Fa "const struct bpf_insn *pc " "u_char *pkt" "u_int wirelen" "u_int buflen" .Fc .Ft int .Fn bpf_validate "const struct bpf_insn *fcode" "int flen" @@ -217,6 +217,12 @@ argument is the length of the original packet and .Fa buflen is the amount of data present. +The +.Fa buflen +value of 0 is special; it indicates that the +.Fa pkt +is actually a pointer to an mbuf chain +.Pq Vt "struct mbuf *" . .Pp The .Fn bpf_validate