[tracker/rss-enclosures] tracker-extract: Fixes NB#172414, check for empty string



commit 06528a5e6bdc5bffead22d658606f4bb4c33574d
Author: Philip Van Hoof <philip codeminded be>
Date:   Wed Jun 9 13:48:19 2010 +0200

    tracker-extract: Fixes NB#172414, check for empty string

 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 604d2ad..36a15d5 100644
--- a/src/tracker-extract/tracker-albumart.c
+++ b/src/tracker-extract/tracker-albumart.c
@@ -430,8 +430,8 @@ albumart_heuristic (const gchar *artist,
 		/* Accept cover, front, folder, AlbumArt_{GUID}_Large
 		 * reject AlbumArt_{GUID}_Small and AlbumArtSmall
 		 */
-		if ((artist_strdown && strstr (name_strdown, artist_strdown)) ||
-		    (album_strdown && strstr (name_strdown, album_strdown)) ||
+		if ((artist_strdown && artist_strdown[0] != '\0' && strstr (name_strdown, artist_strdown)) ||
+		    (album_strdown && album_strdown[0] != '\0' && strstr (name_strdown, album_strdown)) ||
 		    (strstr (name_strdown, "cover")) ||
 		    (strstr (name_strdown, "front")) ||
 		    (strstr (name_strdown, "folder")) ||



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