diff options
author | rpaulo <rpaulo@FreeBSD.org> | 2009-03-21 22:58:08 +0000 |
---|---|---|
committer | rpaulo <rpaulo@FreeBSD.org> | 2009-03-21 22:58:08 +0000 |
commit | 3f19af99adb541ff811a6faaaae340e24ad313c5 (patch) | |
tree | 41d4ee124e8dc2938aa5559c6f422a7b778c807f /contrib/libpcap/pcap-namedb.h | |
parent | b0069d00e9ca6c9d90eb18267d0949527c0249e5 (diff) | |
parent | d8d18f6fbdf4f16ae4382f3d0a2d97953edd9b2c (diff) | |
download | FreeBSD-src-3f19af99adb541ff811a6faaaae340e24ad313c5.zip FreeBSD-src-3f19af99adb541ff811a6faaaae340e24ad313c5.tar.gz |
Merge libpcap 1.0.0.
Diffstat (limited to 'contrib/libpcap/pcap-namedb.h')
-rw-r--r-- | contrib/libpcap/pcap-namedb.h | 59 |
1 files changed, 6 insertions, 53 deletions
diff --git a/contrib/libpcap/pcap-namedb.h b/contrib/libpcap/pcap-namedb.h index bbd06b0..e9ef300 100644 --- a/contrib/libpcap/pcap-namedb.h +++ b/contrib/libpcap/pcap-namedb.h @@ -31,60 +31,13 @@ * SUCH DAMAGE. * * $FreeBSD$ - * @(#) $Header: /tcpdump/master/libpcap/pcap-namedb.h,v 1.10 2005/03/17 07:02:32 guy Exp $ (LBL) + * @(#) $Header: /tcpdump/master/libpcap/pcap-namedb.h,v 1.13 2006/10/04 18:13:32 guy Exp $ (LBL) */ -#ifndef lib_pcap_namedb_h -#define lib_pcap_namedb_h - -#ifdef __cplusplus -extern "C" { -#endif - -/* - * As returned by the pcap_next_etherent() - * XXX this stuff doesn't belong in this interface, but this - * library already must do name to address translation, so - * on systems that don't have support for /etc/ethers, we - * export these hooks since they'll - */ -struct pcap_etherent { - u_char addr[6]; - char name[122]; -}; -#ifndef PCAP_ETHERS_FILE -#define PCAP_ETHERS_FILE "/etc/ethers" -#endif -struct pcap_etherent *pcap_next_etherent(FILE *); -u_char *pcap_ether_hostton(const char*); -u_char *pcap_ether_aton(const char *); - -bpf_u_int32 **pcap_nametoaddr(const char *); -#ifdef INET6 -struct addrinfo *pcap_nametoaddrinfo(const char *); -#endif -bpf_u_int32 pcap_nametonetaddr(const char *); - -int pcap_nametoport(const char *, int *, int *); -int pcap_nametoportrange(const char *, int *, int *, int *); -int pcap_nametoproto(const char *); -int pcap_nametoeproto(const char *); -int pcap_nametollc(const char *); /* - * If a protocol is unknown, PROTO_UNDEF is returned. - * Also, pcap_nametoport() returns the protocol along with the port number. - * If there are ambiguous entried in /etc/services (i.e. domain - * can be either tcp or udp) PROTO_UNDEF is returned. + * For backwards compatibility. + * + * Note to OS vendors: do NOT get rid of this file! Some applications + * might expect to be able to include <pcap-namedb.h>. */ -#define PROTO_UNDEF -1 - -/* XXX move these to pcap-int.h? */ -int __pcap_atodn(const char *, bpf_u_int32 *); -int __pcap_atoin(const char *, bpf_u_int32 *); -u_short __pcap_nametodnaddr(const char *); - -#ifdef __cplusplus -} -#endif - -#endif +#include <pcap/namedb.h> |