diff options
author | Stig Bjørlykke <stig@bjorlykke.org> | 2011-11-04 17:02:33 +0000 |
---|---|---|
committer | Stig Bjørlykke <stig@bjorlykke.org> | 2011-11-04 17:02:33 +0000 |
commit | edc2689422d077335aaf1e16ef01da73b73e0d54 (patch) | |
tree | f55309d9881d05d3c7d9701c61fbba654209c415 | |
parent | 7e24821c3d40fa3389aa342025e6464c921b8e70 (diff) |
Only have the option to turn off syntax check capture filter
if not using threads.
svn path=/trunk/; revision=39732
-rw-r--r-- | epan/prefs.c | 5 | ||||
-rw-r--r-- | gtk/prefs_capture.c | 7 |
2 files changed, 10 insertions, 2 deletions
diff --git a/epan/prefs.c b/epan/prefs.c index 220949fd1b..8e21a8359e 100644 --- a/epan/prefs.c +++ b/epan/prefs.c @@ -2410,8 +2410,9 @@ set_pref(gchar *pref_name, gchar *value, void *private_data _U_, } else if (strcmp(pref_name, PRS_CAP_SHOW_INFO) == 0) { prefs.capture_show_info = ((g_ascii_strcasecmp(value, "true") == 0)?TRUE:FALSE); } else if (strcmp(pref_name, PRS_CAP_SYNTAX_CHECK_FILTER) == 0) { +#ifndef USE_THREADS prefs.capture_syntax_check_filter = ((g_ascii_strcasecmp(value, "true") == 0)?TRUE:FALSE); - +#endif /* handle the global options */ } else if (strcmp(pref_name, PRS_NAME_RESOLVE) == 0 || strcmp(pref_name, PRS_CAP_NAME_RESOLVE) == 0) { @@ -3358,10 +3359,12 @@ write_prefs(char **pf_path_return) fprintf(pf, PRS_CAP_SHOW_INFO ": %s\n", prefs.capture_show_info == TRUE ? "TRUE" : "FALSE"); +#ifndef USE_THREADS fprintf(pf, "\n# Syntax check capture filter?\n"); fprintf(pf, "# TRUE or FALSE (case-insensitive).\n"); fprintf(pf, PRS_CAP_SYNTAX_CHECK_FILTER ": %s\n", prefs.capture_syntax_check_filter == TRUE ? "TRUE" : "FALSE"); +#endif fprintf (pf, "\n######## Printing ########\n"); diff --git a/gtk/prefs_capture.c b/gtk/prefs_capture.c index 7c704732a7..e5e81ef5e4 100644 --- a/gtk/prefs_capture.c +++ b/gtk/prefs_capture.c @@ -100,7 +100,10 @@ GtkWidget* capture_prefs_show(void) { GtkWidget *main_tb, *main_vb; - GtkWidget *if_cbxe, *if_lb, *promisc_cb, *pcap_ng_cb, *sync_cb, *auto_scroll_cb, *show_info_cb, *syntax_check_filter_cb; + GtkWidget *if_cbxe, *if_lb, *promisc_cb, *pcap_ng_cb, *sync_cb, *auto_scroll_cb, *show_info_cb; +#ifndef USE_THREADS + GtkWidget *syntax_check_filter_cb; +#endif GtkWidget *ifopts_lb, *ifopts_bt; GList *if_list, *combo_list; int err; @@ -206,12 +209,14 @@ capture_prefs_show(void) !prefs.capture_show_info); g_object_set_data(G_OBJECT(main_vb), SHOW_INFO_KEY, show_info_cb); +#ifndef USE_THREADS /* Syntax check capture filter */ syntax_check_filter_cb = create_preference_check_button(main_tb, row++, "Syntax check capture filter:", "Syntax check capture filter. Turn this off if you experience delay when writing capture filters.", prefs.capture_syntax_check_filter); g_object_set_data(G_OBJECT(main_vb), SYNTAX_CHECK_FILTER_KEY, syntax_check_filter_cb); +#endif /* Show 'em what we got */ gtk_widget_show_all(main_vb); |