summaryrefslogtreecommitdiff
path: root/sf-pcap.h
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2013-05-06 14:16:14 -0700
committerGuy Harris <guy@alum.mit.edu>2013-05-06 14:16:14 -0700
commite9e96bbc3efd45ba6d1dbb097bc09845ba54c5d6 (patch)
tree88c0719044762ff35a1adedafcea69ab4dc005b5 /sf-pcap.h
parent5c18aa3e68e7d54712102e359efe4567fa81eca8 (diff)
downloadlibpcap-e9e96bbc3efd45ba6d1dbb097bc09845ba54c5d6.tar.gz
Move platform-dependent pcap_t data out of the pcap_t structure.
Put the private data right after the pcap_t structure, with a pointer to it in the pcap_t. The initial goal is to allow new pcap modules to be added without having to hack pcap-int.h. In the longer term, we may want to freeze the pcap_t structure, except possibly for adding new method pointers at the end, and provide an ABI for adding modules. We also put the stuff used by the read path at the beginning of the pcap_t structure, to try to keep it on the same set of cache lines.
Diffstat (limited to 'sf-pcap.h')
-rw-r--r--sf-pcap.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/sf-pcap.h b/sf-pcap.h
index 3b3fbe89..fce6ee58 100644
--- a/sf-pcap.h
+++ b/sf-pcap.h
@@ -31,6 +31,7 @@
#ifndef sf_pcap_h
#define sf_pcap_h
-extern int pcap_check_header(pcap_t *, bpf_u_int32, FILE *, char *);
+extern pcap_t *pcap_check_header(bpf_u_int32 magic, FILE *fp, char *errbuf,
+ int *err);
#endif