On Wed, 2011-11-16 at 11:08 +0800, Gary Ching-Pang Lin wrote: > Although nma_wireless_dialog_get_connection() creates a NMConnection > object for the hidden AP, the object wasn't kept, and the function > would return different NMConnection objects each time.
At least as it's used in nm-applet, the dialog is supposed to be destroyed after that function is called. Is there some other use in the Gnome control center that wants it to stick around? libnm-gtk is currently private API between nm-applet and the control center and it looks like the control center is using it correctly AFAICT. Dan > --- > src/libnm-gtk/nm-wireless-dialog.c | 2 ++ > 1 files changed, 2 insertions(+), 0 deletions(-) > > diff --git a/src/libnm-gtk/nm-wireless-dialog.c > b/src/libnm-gtk/nm-wireless-dialog.c > index 0d79f75..3111037 100644 > --- a/src/libnm-gtk/nm-wireless-dialog.c > +++ b/src/libnm-gtk/nm-wireless-dialog.c > @@ -1236,6 +1236,8 @@ nma_wireless_dialog_get_connection (NMAWirelessDialog > *self, > } > > nm_connection_add_setting (connection, (NMSetting *) > s_wireless); > + > + priv->connection = g_object_ref (connection); > } else > connection = g_object_ref (priv->connection); > _______________________________________________ networkmanager-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/networkmanager-list
