From 9ed89569eaa4da350e45c2446413f048c398a1f7 Mon Sep 17 00:00:00 2001 From: Aaron Burghardt Date: Sun, 30 Jun 2013 20:43:35 -0400 Subject: Fixed memory leak in mb2_status_check_snapshot_state() by freeing the string returned from plist_get_string_val(). --- tools/idevicebackup2.c | 1 + 1 file changed, 1 insertion(+) (limited to 'tools/idevicebackup2.c') diff --git a/tools/idevicebackup2.c b/tools/idevicebackup2.c index 8921403..fe2efdc 100644 --- a/tools/idevicebackup2.c +++ b/tools/idevicebackup2.c @@ -470,6 +470,7 @@ static int mb2_status_check_snapshot_state(const char *path, const char *udid, c plist_get_string_val(node, &sval); if (sval) { ret = (strcmp(sval, matches) == 0) ? 1 : 0; + free(sval); } } else { printf("%s: ERROR could not get SnapshotState key from Status.plist!\n", __func__); -- cgit v1.1-32-gdbae