network-manager-applet r680 - trunk/src/wireless-security
- From: dcbw svn gnome org
- To: svn-commits-list gnome org
- Subject: network-manager-applet r680 - trunk/src/wireless-security
- Date: Thu, 17 Apr 2008 02:00:54 +0100 (BST)
Author: dcbw
Date: Thu Apr 17 02:00:54 2008
New Revision: 680
URL: http://svn.gnome.org/viewvc/network-manager-applet?rev=680&view=rev
Log:
Don't leak a GError
Modified:
trunk/src/wireless-security/eap-method-leap.c
trunk/src/wireless-security/eap-method-simple.c
trunk/src/wireless-security/eap-method-tls.c
trunk/src/wireless-security/ws-leap.c
trunk/src/wireless-security/ws-wep-key.c
trunk/src/wireless-security/ws-wpa-psk.c
Modified: trunk/src/wireless-security/eap-method-leap.c
==============================================================================
--- trunk/src/wireless-security/eap-method-leap.c (original)
+++ trunk/src/wireless-security/eap-method-leap.c Thu Apr 17 02:00:54 2008
@@ -179,7 +179,8 @@
if (value)
gtk_entry_set_text (GTK_ENTRY (widget), g_value_get_string (value));
g_hash_table_destroy (secrets);
- }
+ } else
+ g_error_free (error);
}
widget = glade_xml_get_widget (xml, "show_checkbutton");
Modified: trunk/src/wireless-security/eap-method-simple.c
==============================================================================
--- trunk/src/wireless-security/eap-method-simple.c (original)
+++ trunk/src/wireless-security/eap-method-simple.c Thu Apr 17 02:00:54 2008
@@ -197,7 +197,8 @@
if (value)
gtk_entry_set_text (GTK_ENTRY (widget), g_value_get_string (value));
g_hash_table_destroy (secrets);
- }
+ } else
+ g_error_free (error);
}
widget = glade_xml_get_widget (xml, "show_checkbutton");
Modified: trunk/src/wireless-security/eap-method-tls.c
==============================================================================
--- trunk/src/wireless-security/eap-method-tls.c (original)
+++ trunk/src/wireless-security/eap-method-tls.c Thu Apr 17 02:00:54 2008
@@ -420,7 +420,8 @@
if (value)
gtk_entry_set_text (GTK_ENTRY (widget), g_value_get_string (value));
g_hash_table_destroy (secrets);
- }
+ } else
+ g_error_free (error);
}
setup_filepicker (xml, "eap_tls_user_cert_button",
Modified: trunk/src/wireless-security/ws-leap.c
==============================================================================
--- trunk/src/wireless-security/ws-leap.c (original)
+++ trunk/src/wireless-security/ws-leap.c Thu Apr 17 02:00:54 2008
@@ -173,7 +173,8 @@
if (value)
gtk_entry_set_text (GTK_ENTRY (widget), g_value_get_string (value));
g_hash_table_destroy (secrets);
- }
+ } else
+ g_error_free (error);
}
widget = glade_xml_get_widget (xml, "leap_username_entry");
Modified: trunk/src/wireless-security/ws-wep-key.c
==============================================================================
--- trunk/src/wireless-security/ws-wep-key.c (original)
+++ trunk/src/wireless-security/ws-wep-key.c Thu Apr 17 02:00:54 2008
@@ -335,7 +335,8 @@
strcpy (sec->keys[3], g_value_get_string (value));
g_hash_table_destroy (secrets);
- }
+ } else
+ g_error_free (error);
}
g_signal_connect (G_OBJECT (widget), "changed",
@@ -435,8 +436,11 @@
NM_SETTING_WIRELESS_SECURITY_SETTING_NAME,
FALSE,
&error);
- if (!secrets || (g_hash_table_size (secrets) == 0))
+ if (!secrets || (g_hash_table_size (secrets) == 0)) {
+ if (error)
+ g_error_free (error);
return WEP_KEY_TYPE_PASSPHRASE;
+ }
value = g_hash_table_lookup (secrets, NM_SETTING_WIRELESS_SECURITY_WEP_KEY0);
if (value) {
Modified: trunk/src/wireless-security/ws-wpa-psk.c
==============================================================================
--- trunk/src/wireless-security/ws-wpa-psk.c (original)
+++ trunk/src/wireless-security/ws-wpa-psk.c Thu Apr 17 02:00:54 2008
@@ -204,7 +204,8 @@
if (value)
gtk_entry_set_text (GTK_ENTRY (widget), g_value_get_string (value));
g_hash_table_destroy (secrets);
- }
+ } else
+ g_error_free (error);
}
widget = glade_xml_get_widget (xml, "show_checkbutton");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]