[Telepathy-commits] [telepathy-mission-control/master] Fix two memory leaks.
Alberto Mardegan
alberto.mardegan at nokia.com
Mon Nov 17 00:05:21 PST 2008
---
src/mcd-account-compat.c | 3 +++
src/mcd-account-compat.h | 2 +-
2 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/src/mcd-account-compat.c b/src/mcd-account-compat.c
index 8647662..7bbe127 100644
--- a/src/mcd-account-compat.c
+++ b/src/mcd-account-compat.c
@@ -171,6 +171,7 @@ account_request_channel (McSvcAccountInterfaceCompat *self,
req.requestor_client_id = dbus_g_method_get_sender (context);
_mcd_account_compat_request_channel_nmc4 (MCD_ACCOUNT (self),
&req, &error);
+ g_free (req.requestor_client_id);
if (error)
{
dbus_g_method_return_error (context, error);
@@ -198,6 +199,7 @@ account_request_channel_with_string_handle (McSvcAccountInterfaceCompat *self,
req.requestor_client_id = dbus_g_method_get_sender (context);
_mcd_account_compat_request_channel_nmc4 (MCD_ACCOUNT (self),
&req, &error);
+ g_free (req.requestor_client_id);
if (error)
{
dbus_g_method_return_error (context, error);
@@ -333,6 +335,7 @@ _mcd_account_compat_request_channel_nmc4 (McdAccount *account,
value);
channel = mcd_channel_new_request (properties, 0, NULL);
+ g_hash_table_unref (properties);
req_data = g_slice_new0 (McdAccountCompatReq);
req_data->requestor_serial = req->requestor_serial;
diff --git a/src/mcd-account-compat.h b/src/mcd-account-compat.h
index 62f9e19..f6beaf3 100644
--- a/src/mcd-account-compat.h
+++ b/src/mcd-account-compat.h
@@ -46,7 +46,7 @@ struct mcd_channel_request
const gchar *channel_handle_string;
gint channel_handle_type;
guint requestor_serial;
- const gchar *requestor_client_id;
+ gchar *requestor_client_id;
};
/* not exported */
--
1.5.6.5
More information about the Telepathy-commits
mailing list