Commit 02292575 authored by Lubomir Rintel's avatar Lubomir Rintel

libnma/wifi-dialog: fix assertion failure on changing a device

connection_combo_init() is also called when the device combo is changed.
Don't assume the connection is NULL; it is not going to be.
parent 0de26b27
......@@ -432,11 +432,8 @@ connection_combo_init (NMAWifiDialog *self, NMConnection *connection)
GtkCellRenderer *renderer;
const char *id;
g_return_val_if_fail (priv->connection == NULL, FALSE);
/* Clear any old model */
if (priv->connection_model)
g_object_unref (priv->connection_model);
g_clear_object (&priv->connection_model);
g_clear_object (&priv->connection);
/* New model */
store = gtk_list_store_new (4, G_TYPE_STRING, G_TYPE_OBJECT, G_TYPE_BOOLEAN, G_TYPE_BOOLEAN);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment