/pidgin/main: c7d516ebb630: myspace.c: Fix memleaks in msim_uri_...
Niels Thykier
niels at thykier.net
Sun Jan 27 05:57:49 EST 2013
Changeset: c7d516ebb630af3ddfdbdd6b0106fb81eeee1f8c
Author: Niels Thykier <niels at thykier.net>
Date: 2013-01-26 03:37 -0500
Branch: default
URL: http://hg.pidgin.im/pidgin/main/rev/c7d516ebb630
Description:
myspace.c: Fix memleaks in msim_uri_handler
Refs #15472.
diffstat:
libpurple/protocols/myspace/myspace.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diffs (23 lines):
diff --git a/libpurple/protocols/myspace/myspace.c b/libpurple/protocols/myspace/myspace.c
--- a/libpurple/protocols/myspace/myspace.c
+++ b/libpurple/protocols/myspace/myspace.c
@@ -3577,7 +3577,10 @@ msim_uri_handler(const gchar *proto, con
gc = purple_account_get_connection(account);
session = purple_connection_get_protocol_data(gc);
- g_return_val_if_fail(session != NULL, FALSE);
+ if (session == NULL) {
+ g_free(cid_str);
+ return FALSE;
+ }
/* Lookup userid to username. TODO: push this down, to IM sending/contact
* adding functions. */
@@ -3595,6 +3598,7 @@ msim_uri_handler(const gchar *proto, con
return TRUE;
}
+ g_free(cid_str);
return FALSE;
}
More information about the Commits
mailing list