forked from osmocom/wireshark
If something is only supposed to be included if we have libpcap, don't
put #ifdef HAVE_LIBPCAP in it. Add multiple-inclusion protection to capture_errs.h. svn path=/trunk/; revision=32803
This commit is contained in:
parent
8d56103f48
commit
e36628d2aa
|
@ -25,8 +25,6 @@
|
|||
#ifndef __PCAP_UTIL_INT_H__
|
||||
#define __PCAP_UTIL_INT_H__
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
|
||||
extern if_info_t *if_info_new(char *name, char *description);
|
||||
extern void if_info_add_address(if_info_t *if_info, struct sockaddr *addr);
|
||||
#ifdef HAVE_PCAP_FINDALLDEVS
|
||||
|
@ -44,6 +42,4 @@ extern GList *get_interface_list_findalldevs(int *err, char **err_str);
|
|||
*/
|
||||
extern gchar *cant_get_if_list_error_message(const char *err_str);
|
||||
|
||||
#endif /* HAVE_LIBPCAP */
|
||||
|
||||
#endif /* __PCAP_UTIL_INT_H__ */
|
||||
|
|
|
@ -101,8 +101,6 @@ extern void capture_input_cfilter_error_message(capture_options *capture_opts, c
|
|||
*/
|
||||
extern void capture_input_closed(capture_options *capture_opts);
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
|
||||
struct if_stat_cache_s;
|
||||
typedef struct if_stat_cache_s if_stat_cache_t;
|
||||
|
||||
|
@ -123,6 +121,5 @@ extern gboolean capture_stats(if_stat_cache_t *sc, char *ifname, struct pcap_sta
|
|||
* Stop gathering capture statistics.
|
||||
*/
|
||||
void capture_stat_stop(if_stat_cache_t *sc);
|
||||
#endif /* HAVE_LIBPCAP */
|
||||
|
||||
#endif /* capture.h */
|
||||
|
|
|
@ -23,7 +23,8 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
#ifndef __CAPTURE_ERRS_H__
|
||||
#define __CAPTURE_ERRS_H__
|
||||
|
||||
#ifdef _WIN32
|
||||
/* error message, if WinPcap couldn't be loaded */
|
||||
|
@ -31,4 +32,4 @@
|
|||
extern char *cant_load_winpcap_err(const char *app_name);
|
||||
#endif /* _WIN32 */
|
||||
|
||||
#endif /* HAVE_LIBPCAP */
|
||||
#endif /* __CAPTURE_ERRS_H__ */
|
||||
|
|
|
@ -25,8 +25,6 @@
|
|||
#ifndef __CAPTURE_IFINFO_H__
|
||||
#define __CAPTURE_IFINFO_H__
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
|
||||
/*
|
||||
* The list of interfaces returned by "get_interface_list()" is
|
||||
* a list of these structures.
|
||||
|
@ -94,6 +92,4 @@ capture_get_if_capabilities(const char *devname, gboolean monitor_mode,
|
|||
|
||||
void free_if_capabilities(if_capabilities_t *caps);
|
||||
|
||||
#endif /* HAVE_LIBPCAP */
|
||||
|
||||
#endif /* __CAPTURE_IFINFO_H__ */
|
||||
|
|
|
@ -25,8 +25,6 @@
|
|||
#ifndef __RINGBUFFER_H__
|
||||
#define __RINGBUFFER_H__
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
|
||||
#include <stdio.h>
|
||||
#include "file.h"
|
||||
#include "wiretap/wtap.h"
|
||||
|
@ -47,6 +45,4 @@ gboolean ringbuf_libpcap_dump_close(gchar **save_file, int *err);
|
|||
void ringbuf_free(void);
|
||||
void ringbuf_error_cleanup(void);
|
||||
|
||||
#endif /* HAVE_LIBPCAP */
|
||||
|
||||
#endif /* ringbuffer.h */
|
||||
|
|
Loading…
Reference in New Issue