commit fcbd30f495fa08eba01a71ce289a5e6cdbf81894
Author: Christophe Fergeau <[email protected]>
Date: Sat Jul 25 17:24:03 2009 +0200
fix memory minor leaks
tools/hal-callout.c | 2 ++
tools/ipod-lockdown.c | 2 ++
2 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/tools/hal-callout.c b/tools/hal-callout.c
index 2ad9f02..f148572 100644
--- a/tools/hal-callout.c
+++ b/tools/hal-callout.c
@@ -796,11 +796,13 @@ int main (int argc, char **argv)
ctx = hal_ipod_initialize ();
if (ctx == NULL) {
+ g_free (xml);
itdb_sysinfo_properties_free (props);
return FALSE;
}
udi = g_getenv ("UDI");
if (udi == NULL) {
+ g_free (xml);
libhal_ctx_free (ctx);
itdb_sysinfo_properties_free (props);
return FALSE;
diff --git a/tools/ipod-lockdown.c b/tools/ipod-lockdown.c
index 6253239..c0163a8 100644
--- a/tools/ipod-lockdown.c
+++ b/tools/ipod-lockdown.c
@@ -64,11 +64,13 @@ read_sysinfo_extended_by_uuid (const char *uuid)
plist_add_sub_key_el(value, "SerialNumber");
plist_get_string_val(ptr, &str);
plist_add_sub_string_el(value, str);
+ free(str);
ptr = plist_get_dict_el_from_key(global, "BuildVersion");
plist_add_sub_key_el(value, "BuildID");
plist_get_string_val(ptr, &str);
plist_add_sub_string_el(value, str);
+ free(str);
plist_to_xml(value, &xml, &xml_length);
------------------------------------------------------------------------------
Return on Information:
Google Enterprise Search pays you back
Get the facts.
http://p.sf.net/sfu/google-dev2dev
_______________________________________________
gtkpod-cvs2 mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gtkpod-cvs2