[network-manager-openvpn] properties: fix a memory leak in import code



commit 0bda37998f1c506ad9d29126bd263d7a7588f747
Author: Jiří Klimeš <jklimes redhat com>
Date:   Thu Mar 20 16:03:30 2014 +0100

    properties: fix a memory leak in import code

 properties/import-export.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)
---
diff --git a/properties/import-export.c b/properties/import-export.c
index 804fc3c..a4b2560 100644
--- a/properties/import-export.c
+++ b/properties/import-export.c
@@ -432,9 +432,7 @@ do_import (const char *path, char **lines, GError **error)
 
                if (   !strncmp (*line, HTTP_PROXY_RETRY_TAG, strlen (HTTP_PROXY_RETRY_TAG))
                    || !strncmp (*line, SOCKS_PROXY_RETRY_TAG, strlen (SOCKS_PROXY_RETRY_TAG))) {
-                       nm_setting_vpn_add_data_item (s_vpn,
-                                                     g_strdup (NM_OPENVPN_KEY_PROXY_RETRY),
-                                                     g_strdup ("yes"));
+                       nm_setting_vpn_add_data_item (s_vpn, NM_OPENVPN_KEY_PROXY_RETRY, "yes");
                        continue;
                }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]