[maemo-commits] [maemo-commits] r17000 - in projects/haf/trunk/hildon-thumbnail: . daemon

From: subversion at stage.maemo.org subversion at stage.maemo.org
Date: Thu Dec 18 11:05:14 EET 2008
Author: pvanhoof
Date: 2008-12-18 11:05:13 +0200 (Thu, 18 Dec 2008)
New Revision: 17000

Modified:
   projects/haf/trunk/hildon-thumbnail/ChangeLog
   projects/haf/trunk/hildon-thumbnail/daemon/utils.c
Log:
2008-12-18   Suarez Romero Juan Antonio  <jasuarez at igalia.com>

        * Bug# 96208: Single-char artist/album generates the same ID for
        hildon-thumbnail



Modified: projects/haf/trunk/hildon-thumbnail/ChangeLog
===================================================================
--- projects/haf/trunk/hildon-thumbnail/ChangeLog	2008-12-17 15:58:26 UTC (rev 16999)
+++ projects/haf/trunk/hildon-thumbnail/ChangeLog	2008-12-18 09:05:13 UTC (rev 17000)
@@ -1,3 +1,8 @@
+2008-12-18   Suarez Romero Juan Antonio  <jasuarez at igalia.com>
+
+	* Bug# 96208: Single-char artist/album generates the same ID for
+	hildon-thumbnail
+
 2008-12-16  Marius Vollmer  <marius.vollmer at nokia.com>
 
 	Released 3.0.16

Modified: projects/haf/trunk/hildon-thumbnail/daemon/utils.c
===================================================================
--- projects/haf/trunk/hildon-thumbnail/daemon/utils.c	2008-12-17 15:58:26 UTC (rev 16999)
+++ projects/haf/trunk/hildon-thumbnail/daemon/utils.c	2008-12-18 09:05:13 UTC (rev 17000)
@@ -293,17 +293,20 @@
 		return;
 	}
 
-	if (a && strlen (a) > 1)
+	if (!a || *a == '\0') 
+		f_a = g_strdup ("  ");
+	else if (strlen (a) == 1)
+		f_a = g_strconcat (a, " ");
+	else
 		f_a = strip_characters (a);
-	else 
-		f_a = g_strdup ("  ");
 
-	if (b && strlen (b) > 1)
+	if (!b || *b == '\0')
+		f_b = g_strdup ("  ");
+	else if (strlen (b) == 1)
+		f_b = g_strconcat (b, " ");
+	else
 		f_b = strip_characters (b);
-	else
-		f_b = g_strdup ("  ");
 
-
 	down1 = g_utf8_strdown (f_a, -1);
 	down2 = g_utf8_strdown (f_b, -1);
 


More information about the maemo-commits mailing list