song: song_get_url: fix "/" prefix for songs in music_root

This commit is contained in:
Eric Wong 2008-10-13 09:39:02 +02:00 committed by Max Kellermann
parent 2139d8bba8
commit c641aabe33

View File

@ -124,7 +124,7 @@ song_get_url(struct song *song, char *path_max_tmp)
assert(song != NULL);
assert(*song->url);
if (!song->parent || !song->parent->path)
if (!song->parent || isRootDirectory(song->parent->path))
strcpy(path_max_tmp, song->url);
else
pfx_dir(path_max_tmp, song->url, strlen(song->url),