aboutsummaryrefslogtreecommitdiffstats
path: root/epan/prefs.c
diff options
context:
space:
mode:
authorPascal Quantin <pascal.quantin@gmail.com>2012-07-06 12:25:54 +0000
committerPascal Quantin <pascal.quantin@gmail.com>2012-07-06 12:25:54 +0000
commit7e38fe433aa3ac3857c11ed41fee789ff7d6d048 (patch)
tree9eaf50e223f54acd37b3b0ad93186fcb6418a5d4 /epan/prefs.c
parent88cb14dda3faf752e41ca6ce3f1ccac7d4920548 (diff)
Fix compilation with gcc 4.3.2 and without GEOIP
svn path=/trunk/; revision=43587
Diffstat (limited to 'epan/prefs.c')
-rw-r--r--epan/prefs.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/epan/prefs.c b/epan/prefs.c
index ff1a229cdd..0a99766688 100644
--- a/epan/prefs.c
+++ b/epan/prefs.c
@@ -42,7 +42,9 @@
#include <epan/address.h>
#include <epan/addr_resolv.h>
#include <epan/oids.h>
+#ifdef HAVE_GEOIP
#include <epan/geoip_db.h>
+#endif
#include <epan/packet.h>
#include <epan/prefs.h>
#include <epan/proto.h>
@@ -982,7 +984,9 @@ prefs_register_modules(void)
"Name Resolution", NULL);
addr_resolve_pref_init(nameres_module);
oid_pref_init(nameres_module);
+#ifdef HAVE_GEOIP
geoip_db_pref_init(nameres_module);
+#endif
/* Printing */
printing = prefs_register_module(NULL, "print", "Printing",
@@ -998,11 +1002,11 @@ prefs_register_modules(void)
#ifndef _WIN32
prefs_register_string_preference(printing, "command", "Command",
- "Output gets piped to this command when the destination is set to \"command\"", &prefs.pr_cmd);
+ "Output gets piped to this command when the destination is set to \"command\"", (const char**)(&prefs.pr_cmd));
#endif
prefs_register_filename_preference(printing, "file", "File",
- "This is the file that gets written to when the destination is set to \"file\"", &prefs.pr_file);
+ "This is the file that gets written to when the destination is set to \"file\"", (const char**)(&prefs.pr_file));
/* Statistics */
@@ -2206,9 +2210,6 @@ prefs_capture_device_monitor_mode(const char *name)
#define GREEN_COMPONENT(x) (guint16) (((((x) >> 8) & 0xff) * 65535 / 255))
#define BLUE_COMPONENT(x) (guint16) ( (((x) & 0xff) * 65535 / 255))
-static const gchar *pr_formats[] = { "text", "postscript" };
-static const gchar *pr_dests[] = { "command", "file" };
-
char
string_to_name_resolve(char *string, e_addr_resolve *name_resolve)
{