aboutsummaryrefslogtreecommitdiffstats
path: root/capture_ui_utils.c
diff options
context:
space:
mode:
authorMichael Mann <mmann78@netscape.net>2012-08-08 16:54:02 +0000
committerMichael Mann <mmann78@netscape.net>2012-08-08 16:54:02 +0000
commite0e533d643fbac41ddea4dc7495dc4fed221aff9 (patch)
treeffcde6212c6ab8975a3feeafb83ae54361835e3a /capture_ui_utils.c
parent68e2e8b8891385efe6126fa1b5a578e9fc693fe4 (diff)
Have (almost) all preferences use the generic preferences API (per https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7402). This cleaned up a lot of hardcoded code and allows breaking up the prefs structure (or at least prevent it from growing too large) if desired.
Bugfixed problems mentioned in http://www.wireshark.org/lists/wireshark-dev/201208/msg00001.html Column preferences now support default '#' character svn path=/trunk/; revision=44348
Diffstat (limited to 'capture_ui_utils.c')
-rw-r--r--capture_ui_utils.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/capture_ui_utils.c b/capture_ui_utils.c
index 8ba64f9f0a..7e3f680660 100644
--- a/capture_ui_utils.c
+++ b/capture_ui_utils.c
@@ -55,7 +55,8 @@ capture_dev_user_descr_find(const gchar *if_name)
int lp = 0;
int ct = 0;
- if (prefs.capture_devices_descr == NULL) {
+ if ((prefs.capture_devices_descr == NULL) ||
+ (*prefs.capture_devices_descr == '\0')) {
/* There are no descriptions. */
return NULL;
}
@@ -108,7 +109,8 @@ capture_dev_user_linktype_find(const gchar *if_name)
gchar *p, *next;
long linktype;
- if (prefs.capture_devices_linktypes == NULL) {
+ if ((prefs.capture_devices_linktypes == NULL) ||
+ (*prefs.capture_devices_linktypes == '\0')) {
/* There are no link-layer header types */
return -1;
}