summaryrefslogtreecommitdiff
path: root/playlist.c
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <wakeroid@gmail.com>2009-12-23 18:13:00 +0100
committerGravatar Alexey Yakovenko <wakeroid@gmail.com>2009-12-23 18:13:00 +0100
commita0a7b8cddee95795eee175392416f29398fe4cd4 (patch)
tree7a20134b2494e8f5390813d668f8e5399ae49776 /playlist.c
parenta1726f5d5bb1ef5ceb3e1770956e24629378392c (diff)
fixed pl_format_title regression
Diffstat (limited to 'playlist.c')
-rw-r--r--playlist.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/playlist.c b/playlist.c
index a9c1a55e..fce8f0a4 100644
--- a/playlist.c
+++ b/playlist.c
@@ -1647,9 +1647,9 @@ pl_format_title (playItem_t *it, char *s, int size, int id, const char *fmt) {
case DB_COLUMN_ARTIST_ALBUM:
{
char artistalbum[1024];
- snprintf (artistalbum, sizeof (artistalbum), "%s - %s",
- artist = pl_get_meta_cached (it, "artist", artist, "?"),
- album = pl_get_meta_cached (it, "album", album, "?"));
+ artist = pl_get_meta_cached (it, "artist", artist, "?");
+ album = pl_get_meta_cached (it, "album", album, "?");
+ snprintf (artistalbum, sizeof (artistalbum), "%s - %s", artist, album);
text = artistalbum;
}
break;
@@ -1715,10 +1715,7 @@ pl_format_title (playItem_t *it, char *s, int size, int id, const char *fmt) {
}
if (meta) {
- const char *value = pl_find_meta (it, meta);
- if (!value) {
- value = "?";
- }
+ const char *value = meta;
while (n > 0 && *value) {
*s++ = *value++;
n--;