mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-07-23 19:24:38 +00:00
2004-07-27 Dan Williams <dcbw@redhat.com>
* info-daemon/NetworkManagerInfo.c - Update allowed network's GConf key when user enters a WEP key explicitly * info-daemon/NetworkManagerDbus.c - Fix some comments - nmi_dbus_get_allowed_networks(): kill warning git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@26 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
parent
8945fdfd7c
commit
be590d9793
|
@ -1,3 +1,12 @@
|
|||
2004-07-27 Dan Williams <dcbw@redhat.com>
|
||||
|
||||
* info-daemon/NetworkManagerInfo.c
|
||||
- Update allowed network's GConf key when user enters a WEP key explicitly
|
||||
|
||||
* info-daemon/NetworkManagerDbus.c
|
||||
- Fix some comments
|
||||
- nmi_dbus_get_allowed_networks(): kill warning
|
||||
|
||||
2004-07-27 Dan Williams <dcbw@redhat.com>
|
||||
|
||||
* initscript/Makefile.in
|
||||
|
|
|
@ -90,8 +90,24 @@ static void ok_button_clicked (GtkWidget *ok_button, gpointer user_data)
|
|||
const char *passphrase = gtk_entry_get_text (GTK_ENTRY (entry));
|
||||
const char *device = g_object_get_data (G_OBJECT (dialog), "device");
|
||||
const char *network = g_object_get_data (G_OBJECT (dialog), "network");
|
||||
gchar *key = NULL;
|
||||
GConfEntry *gconf_entry;
|
||||
|
||||
/* Tell NetworkManager about the key the user typed in */
|
||||
nmi_dbus_return_user_key (info->connection, device, network, passphrase);
|
||||
|
||||
/* Update GConf with the new user key */
|
||||
key = g_strdup_printf ("%s/%s", NMI_GCONF_ALLOWED_NETWORKS_PATH, network);
|
||||
gconf_entry = gconf_client_get_entry (info->gconf_client, key, NULL, TRUE, NULL);
|
||||
g_free (key);
|
||||
if (gconf_entry)
|
||||
{
|
||||
gconf_entry_unref (gconf_entry);
|
||||
key = g_strdup_printf ("%s/%s/key", NMI_GCONF_ALLOWED_NETWORKS_PATH, network);
|
||||
gconf_client_set_string (info->gconf_client, key, passphrase, NULL);
|
||||
g_free (key);
|
||||
}
|
||||
|
||||
nmi_clear_dialog (dialog, entry);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -193,7 +193,7 @@ static DBusMessage *nmi_dbus_get_allowed_networks (NMIAppInfo *info, DBusMessage
|
|||
gchar key[100];
|
||||
GConfValue *value;
|
||||
|
||||
g_snprintf (&key[0], 99, "%s/essid", element->data);
|
||||
g_snprintf (&key[0], 99, "%s/essid", (char *)(element->data));
|
||||
value = gconf_client_get (info->gconf_client, key, NULL);
|
||||
if (value && gconf_value_get_string (value))
|
||||
{
|
||||
|
@ -242,7 +242,7 @@ static DBusMessage *nmi_dbus_get_allowed_network_prio (NMIAppInfo *info, DBusMes
|
|||
return (reply_message);
|
||||
}
|
||||
|
||||
/* List all allowed access points that gconf knows about */
|
||||
/* Grab priority key for our access point from GConf */
|
||||
key = g_strdup_printf ("%s/%s/priority", NMI_GCONF_ALLOWED_NETWORKS_PATH, network);
|
||||
value = gconf_client_get (info->gconf_client, key, NULL);
|
||||
g_free (key);
|
||||
|
@ -290,7 +290,7 @@ static DBusMessage *nmi_dbus_get_allowed_network_essid (NMIAppInfo *info, DBusMe
|
|||
return (reply_message);
|
||||
}
|
||||
|
||||
/* List all allowed access points that gconf knows about */
|
||||
/* Grab essid key for our access point from GConf */
|
||||
key = g_strdup_printf ("%s/%s/essid", NMI_GCONF_ALLOWED_NETWORKS_PATH, network);
|
||||
value = gconf_client_get (info->gconf_client, key, NULL);
|
||||
g_free (key);
|
||||
|
@ -338,7 +338,7 @@ static DBusMessage *nmi_dbus_get_allowed_network_key (NMIAppInfo *info, DBusMess
|
|||
return (reply_message);
|
||||
}
|
||||
|
||||
/* List all allowed access points that gconf knows about */
|
||||
/* Grab user-key key for our access point from GConf */
|
||||
key = g_strdup_printf ("%s/%s/key", NMI_GCONF_ALLOWED_NETWORKS_PATH, network);
|
||||
value = gconf_client_get (info->gconf_client, key, NULL);
|
||||
g_free (key);
|
||||
|
|
Loading…
Reference in a new issue