From 8c286b46869ea6e139efe44b3ee553bcc19219e9 Mon Sep 17 00:00:00 2001 From: Konstantin Kudakov Date: Fri, 3 Jan 2014 16:30:26 +0100 Subject: cuesheet: Search for /path/to/music.mp3.cue as well if all fails. Change-Id: If58ea7c7b94de54f6d9b014f069807bb88c6a147 --- apps/cuesheet.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'apps') diff --git a/apps/cuesheet.c b/apps/cuesheet.c index 354f976997..b7b7df85a8 100644 --- a/apps/cuesheet.c +++ b/apps/cuesheet.c @@ -75,7 +75,12 @@ bool look_for_cuesheet_file(struct mp3entry *track_id3, struct cuesheet_file *cu char *dot = strrchr(cuepath, '.'); strcpy(dot, ".cue"); if (!file_exists(cuepath)) - return false; + { + strlcpy(cuepath, track_id3->path, MAX_PATH); + strlcat(cuepath, ".cue", MAX_PATH); + if (!file_exists(cuepath)) + return false; + } } strlcpy(cue_file->path, cuepath, MAX_PATH); -- cgit v1.2.3