diff src/cue/cuesheet.c @ 532:04b0c54d16bb trunk

[svn] - if the performer of a track is not specified in cue sheet, the performer of the album will be used.
author yaz
date Tue, 23 Jan 2007 03:00:28 -0800
parents 8f1785471613
children d5782f3bd760
line wrap: on
line diff
--- a/src/cue/cuesheet.c	Mon Jan 22 22:23:12 2007 -0800
+++ b/src/cue/cuesheet.c	Tue Jan 23 03:00:28 2007 -0800
@@ -24,6 +24,7 @@
 #include <audacious/playlist.h>
 #include <audacious/vfs.h>
 #include <audacious/util.h>
+#include <audacious/strings.h>
 #include <audacious/main.h>
 #include <audacious/strings.h>
 
@@ -213,7 +214,8 @@
 	bmp_title_input_free(phys_tuple);
 
 	out->track_name = g_strdup(cue_tracks[track].title);
-	out->performer = g_strdup(cue_tracks[track].performer);
+	out->performer = g_strdup(cue_tracks[track].performer ?
+				  cue_tracks[track].performer : cue_performer);
 	out->album_name = g_strdup(cue_title);
 	out->genre = g_strdup(cue_genre);
 	out->year = cue_year ? atoi(cue_year) : 0;