diff options
author | Chris Maynard <Christopher.Maynard@GTECH.COM> | 2013-11-27 05:31:10 +0000 |
---|---|---|
committer | Chris Maynard <Christopher.Maynard@GTECH.COM> | 2013-11-27 05:31:10 +0000 |
commit | 5d44edf894c46c2441b59e6338d03b7b7dbd4778 (patch) | |
tree | e05f679a63c27214784b0cb66e79b374e6873bdc /ui | |
parent | eabd5d8534eb356d7be4f78b4a79eb6917d17a89 (diff) |
While r53608 fixed the "Use promiscuous mode on all interfaces" toggle button behavior, it wasn't enough, so use the technique from r53609 for the "Capture on all interfaces" toggle button to fix it completely.
#BACKPORT(1.10)
svn path=/trunk/; revision=53611
Diffstat (limited to 'ui')
-rw-r--r-- | ui/gtk/capture_dlg.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ui/gtk/capture_dlg.c b/ui/gtk/capture_dlg.c index a412b7b1d9..815236c107 100644 --- a/ui/gtk/capture_dlg.c +++ b/ui/gtk/capture_dlg.c @@ -247,6 +247,7 @@ static guint num_selected = 0; #endif static gulong capture_all_handler_id; +static gulong promisc_all_handler_id; static void capture_prep_file_cb(GtkWidget *file_bt, GtkWidget *file_te); @@ -4498,7 +4499,9 @@ update_properties_all(void) /* If all selected interfaces are in promiscuous mode, check the global "promiscuous mode" checkbox, otherwise un-check it. */ promisc_b = (GtkWidget *)g_object_get_data(G_OBJECT(cap_open_w), E_CAP_PROMISC_KEY_ALL); + g_signal_handler_block(promisc_b, promisc_all_handler_id); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(promisc_b), promisc_all); + g_signal_handler_unblock(promisc_b, promisc_all_handler_id); /* If all selected interfaces have the same filter string, set the global filter string to it. */ @@ -4813,7 +4816,7 @@ capture_prep_cb(GtkWidget *w _U_, gpointer d _U_) } else { gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(promisc_cb), get_all_prom_mode()); } - g_signal_connect(promisc_cb, "toggled", G_CALLBACK(promisc_mode_callback), NULL); + promisc_all_handler_id = g_signal_connect(promisc_cb, "toggled", G_CALLBACK(promisc_mode_callback), NULL); gtk_widget_set_tooltip_text(promisc_cb, "Usually a network adapter will only capture the traffic sent to its own network address. " |