aboutsummaryrefslogtreecommitdiff
path: root/contrib/libpcap/pcap_create.3pcap
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/libpcap/pcap_create.3pcap')
-rw-r--r--contrib/libpcap/pcap_create.3pcap20
1 files changed, 10 insertions, 10 deletions
diff --git a/contrib/libpcap/pcap_create.3pcap b/contrib/libpcap/pcap_create.3pcap
index 5a15007bfc30..f08ac5c2b877 100644
--- a/contrib/libpcap/pcap_create.3pcap
+++ b/contrib/libpcap/pcap_create.3pcap
@@ -17,7 +17,7 @@
.\" WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
.\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
.\"
-.TH PCAP_CREATE 3PCAP "3 January 2014"
+.TH PCAP_CREATE 3PCAP "30 November 2023"
.SH NAME
pcap_create \- create a live capture handle
.SH SYNOPSIS
@@ -36,7 +36,7 @@ pcap_t *pcap_create(const char *source, char *errbuf);
.ft
.fi
.SH DESCRIPTION
-.B pcap_create()
+.BR pcap_create ()
is used to create a packet capture handle to look
at packets on the network.
.I source
@@ -46,16 +46,20 @@ with 2.2 or later kernels, a
argument of "any" or
.B NULL
can be used to capture packets from all interfaces.
+.I errbuf
+is a buffer large enough to hold at least
+.B PCAP_ERRBUF_SIZE
+chars.
.PP
The returned handle must be activated with
-.B pcap_activate(3PCAP)
+.BR pcap_activate (3PCAP)
before packets can be captured
with it; options for the capture, such as promiscuous mode, can be set
on the handle before activating it.
.SH RETURN VALUE
-.B pcap_create()
+.BR pcap_create ()
returns a
-.I pcap_t *
+.B pcap_t *
on success and
.B NULL
on failure.
@@ -64,9 +68,5 @@ If
is returned,
.I errbuf
is filled in with an appropriate error message.
-.I errbuf
-is assumed to be able to hold at least
-.B PCAP_ERRBUF_SIZE
-chars.
.SH SEE ALSO
-pcap(3PCAP)
+.BR pcap (3PCAP)