[tracker: 11/12] tracker-extract: Bugfix, strcmp wrongly used and double free



commit 7236ac35b23fd843305fb64d74266507fcd56618
Author: Philip Van Hoof <philip codeminded be>
Date:   Fri Aug 19 15:43:23 2011 +0200

    tracker-extract: Bugfix, strcmp wrongly used and double free

 src/tracker-extract/tracker-albumart.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/tracker-extract/tracker-albumart.c b/src/tracker-extract/tracker-albumart.c
index 52f72a1..70b2fdb 100644
--- a/src/tracker-extract/tracker-albumart.c
+++ b/src/tracker-extract/tracker-albumart.c
@@ -173,7 +173,7 @@ convert_from_other_format (const gchar *found,
 
 	retval = tracker_albumart_file_to_jpeg (found, target_temp);
 
-	if (retval && (artist == NULL || g_strcmp0 (artist, " "))) {
+	if (retval && (artist == NULL || g_strcmp0 (artist, " ") == 0)) {
 		g_rename (target_temp, album_path);
 	} else if (retval && file_get_checksum_if_exists (G_CHECKSUM_MD5, target_temp, &sum1, FALSE, NULL)) {
 		gchar *sum2 = NULL;
@@ -191,7 +191,7 @@ convert_from_other_format (const gchar *found,
 				}
 
 				g_unlink (target_temp);
-				g_free (sum2);
+
 			} else {
 
 				/* If album-space-md5.jpg isn't the same as found,



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