summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2017-11-06 12:58:57 +0100
committerThomas Haller <thaller@redhat.com>2017-11-06 12:58:58 +0100
commit32af8903041fef276b63fe86770bb9a3e96f207e (patch)
tree6a19d0f95bd2bbdf8743d5c541cb545f7a6f76a5
parente552c19962e70c7133b16b2581516720dd7d43b5 (diff)
downloadnetwork-manager-applet-32af8903041fef276b63fe86770bb9a3e96f207e.tar.gz
c-e: avoid crash by disconnecting signal in page-wifi
Open connection-editor for Wi-Fi connection, edit the Wi-Fi channel and leave the cursor inside the channel input field. Then press ESC to close the window. This lead to a crash: #4 0x0000000000428edd in channel_spin_input_cb (spin=0xc18f90 [GtkSpinButton], new_val=0x7fffffffc168, user_data=0xc0a490) at src/connection-editor/page-wifi.c:134
-rw-r--r--src/connection-editor/page-wifi.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/connection-editor/page-wifi.c b/src/connection-editor/page-wifi.c
index 32a54b44..c6948a52 100644
--- a/src/connection-editor/page-wifi.c
+++ b/src/connection-editor/page-wifi.c
@@ -334,12 +334,14 @@ populate_ui (CEPageWifi *self)
mode_combo_changed_cb (priv->mode, self);
g_signal_connect (priv->mode, "changed", G_CALLBACK (mode_combo_changed_cb), self);
- g_signal_connect (priv->channel, "output",
- G_CALLBACK (channel_spin_output_cb),
- self);
- g_signal_connect (priv->channel, "input",
- G_CALLBACK (channel_spin_input_cb),
- self);
+ g_signal_connect_object (priv->channel, "output",
+ G_CALLBACK (channel_spin_output_cb),
+ self,
+ 0);
+ g_signal_connect_object (priv->channel, "input",
+ G_CALLBACK (channel_spin_input_cb),
+ self,
+ 0);
gtk_widget_set_sensitive (GTK_WIDGET (priv->channel), FALSE);
if (band) {