network-manager-applet r1183 - in trunk: . src src/gconf-helpers
- From: dcbw svn gnome org
- To: svn-commits-list gnome org
- Subject: network-manager-applet r1183 - in trunk: . src src/gconf-helpers
- Date: Wed, 18 Feb 2009 16:45:10 +0000 (UTC)
Author: dcbw
Date: Wed Feb 18 16:45:10 2009
New Revision: 1183
URL: http://svn.gnome.org/viewvc/network-manager-applet?rev=1183&view=rev
Log:
2009-02-18 Dan Williams <dcbw redhat com>
Patch by paolo borelli <pborelli katamail com>
* src/applet.c
src/gconf-helpers/gconf-upgrade.c
src/wireless-dialog.c
- Fix some memory leaks (bgo #570869)
Modified:
trunk/ChangeLog
trunk/src/applet.c
trunk/src/gconf-helpers/gconf-upgrade.c
trunk/src/wireless-dialog.c
Modified: trunk/src/applet.c
==============================================================================
--- trunk/src/applet.c (original)
+++ trunk/src/applet.c Wed Feb 18 16:45:10 2009
@@ -1936,7 +1936,6 @@
GdkPixbuf *pixbuf = NULL;
NMState state;
char *dev_tip = NULL, *vpn_tip = NULL;
- GString *tip;
NMVPNConnectionState vpn_state = NM_VPN_SERVICE_STATE_UNKNOWN;
gboolean nm_running;
NMActiveConnection *active_vpn = NULL;
@@ -2000,6 +1999,8 @@
}
if (dev_tip || vpn_tip) {
+ GString *tip;
+
tip = g_string_new (dev_tip);
if (vpn_tip)
@@ -2008,6 +2009,8 @@
if (tip->len)
applet->tip = tip->str;
+ g_free (vpn_tip);
+ g_free (dev_tip);
g_string_free (tip, FALSE);
}
@@ -2589,6 +2592,9 @@
if (applet->gconf_client)
g_object_unref (applet->gconf_client);
+ if (applet->encryption_size_group)
+ g_object_unref (applet->encryption_size_group);
+
if (applet->status_icon)
g_object_unref (applet->status_icon);
Modified: trunk/src/gconf-helpers/gconf-upgrade.c
==============================================================================
--- trunk/src/gconf-helpers/gconf-upgrade.c (original)
+++ trunk/src/gconf-helpers/gconf-upgrade.c Wed Feb 18 16:45:10 2009
@@ -1191,6 +1191,7 @@
NM_SETTING_IP4_CONFIG_SETTING_NAME,
new);
}
+ g_array_free (array, TRUE);
g_array_free (new, TRUE);
next:
@@ -1467,6 +1468,7 @@
/* delete old vpn-properties dir */
gconf_client_recursive_unset (client, path, 0, NULL);
+ g_free (path);
}
nm_utils_slist_free (connections, g_free);
@@ -1540,8 +1542,11 @@
&service))
continue;
- if (!service || strcmp (service, "org.freedesktop.NetworkManager.openvpn"))
+ if (!service || strcmp (service, "org.freedesktop.NetworkManager.openvpn")) {
+ g_free (service);
continue;
+ }
+ g_free (service);
move_one_vpn_string_bool (client, iter->data, "dev", "tap-dev");
move_one_vpn_string_bool (client, iter->data, "proto", "proto-tcp");
@@ -1563,6 +1568,7 @@
new_type = "password";
else if (!strcmp (old_type, "3"))
new_type = "password-tls";
+ g_free (old_type);
if (new_type) {
nm_gconf_set_string_helper (client, (const char *) iter->data,
Modified: trunk/src/wireless-dialog.c
==============================================================================
--- trunk/src/wireless-dialog.c (original)
+++ trunk/src/wireless-dialog.c Wed Feb 18 16:45:10 2009
@@ -411,7 +411,7 @@
gtk_list_store_append (store, &tree_iter);
gtk_list_store_set (store, &tree_iter,
- C_NAME_COLUMN, g_strdup (_("New...")),
+ C_NAME_COLUMN, _("New..."),
C_NEW_COLUMN, TRUE, -1);
gtk_list_store_append (store, &tree_iter);
@@ -558,7 +558,7 @@
g_assert (desc);
gtk_list_store_append (model, &iter);
- gtk_list_store_set (model, &iter, D_NAME_COLUMN, g_strdup (desc), D_DEV_COLUMN, device, -1);
+ gtk_list_store_set (model, &iter, D_NAME_COLUMN, desc, D_DEV_COLUMN, device, -1);
}
static gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]