X-Git-Url: https://git.tcpdump.org/libpcap/blobdiff_plain/24dcde9062f83c82a24de833e673206319384f4b..cc3ca65d6519faf3a0e4609b5150757c14af36e9:/pcap-int.h diff --git a/pcap-int.h b/pcap-int.h index 1f5c1528..c5a030f5 100644 --- a/pcap-int.h +++ b/pcap-int.h @@ -108,7 +108,7 @@ extern "C" { #define MAXIMUM_SNAPLEN 262144 struct pcap_opt { - char *source; + char *device; int timeout; /* timeout for buffering */ int buffer_size; int promisc; @@ -447,7 +447,7 @@ int pcap_setnonblock_fd(pcap_t *p, int, char *); * by pcap_create routines. */ pcap_t *pcap_create_interface(const char *, char *); -pcap_t *pcap_create_common(const char *, char *, size_t); +pcap_t *pcap_create_common(char *, size_t); int pcap_do_addexit(pcap_t *); void pcap_add_to_pcaps_to_close(pcap_t *); void pcap_remove_from_pcaps_to_close(pcap_t *); @@ -457,17 +457,20 @@ int pcap_check_activated(pcap_t *); /* * Internal interfaces for "pcap_findalldevs()". * - * "pcap_findalldevs_interfaces()" finds interfaces using the - * "standard" mechanisms (SIOCGIFCONF, "getifaddrs()", etc.). - * * "pcap_platform_finddevs()" is a platform-dependent routine to - * add devices not found by the "standard" mechanisms. + * find local network interfaces. + * + * "pcap_findalldevs_interfaces()" is a helper to find those interfaces + * using the "standard" mechanisms (SIOCGIFCONF, "getifaddrs()", etc.). * * "pcap_add_if()" adds an interface to the list of interfaces, for * use by various "find interfaces" routines. */ -int pcap_findalldevs_interfaces(pcap_if_t **, char *); int pcap_platform_finddevs(pcap_if_t **, char *); +#if !defined(_WIN32) && !defined(MSDOS) +int pcap_findalldevs_interfaces(pcap_if_t **, char *, + int (*)(const char *)); +#endif int add_addr_to_iflist(pcap_if_t **, const char *, bpf_u_int32, struct sockaddr *, size_t, struct sockaddr *, size_t, struct sockaddr *, size_t, struct sockaddr *, size_t, char *);