From 53b4d3d1512fa76425c42f0bd46f8e7fb7dc5bad Mon Sep 17 00:00:00 2001 From: morriss Date: Wed, 22 Aug 2007 18:56:20 +0000 Subject: gcc 4 doesn't like my macro for getting the interface description: it says there's an invalid lvalue in it. I don't see what's wrong with it, but replace the macro with a function. Also: don't include the .xpm files in gtk/main.c if we're building without PCAP (as they're not used in that configuration). git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@22588 f5534014-38df-0310-8fa8-9805f1628bb7 --- capture_ui_utils.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'capture_ui_utils.c') diff --git a/capture_ui_utils.c b/capture_ui_utils.c index 33a4b9c1fe..04d806b0bd 100644 --- a/capture_ui_utils.c +++ b/capture_ui_utils.c @@ -346,4 +346,17 @@ get_if_name(const char *if_text) return if_name; } +/* Return capture_opts->iface_descr (after setting it if it is not set) + * This is necessary because capture_opts.c can't set iface_descr (at least + * not without adding significant dependencies there). + */ +const char * +get_iface_description(capture_options *capture_opts) +{ + if (!capture_opts->iface_descr) + capture_opts->iface_descr = get_interface_descriptive_name(capture_opts->iface); + + return(capture_opts->iface_descr); + +} #endif /* HAVE_LIBPCAP */ -- cgit v1.2.3