From 7812cd9286fa7581b5ea18337e875ad98a2d8bd6 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 27 Sep 2008 02:03:07 -0700 Subject: advance to the next song on decoder errors Fix this regression introduced in the core rewrite so that we now skip to the next song when we encounter an error with the song we tried to decode. --- src/playlist.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/playlist.c') diff --git a/src/playlist.c b/src/playlist.c index d454b4ad2..8b7416d2e 100644 --- a/src/playlist.c +++ b/src/playlist.c @@ -528,7 +528,11 @@ static void syncPlaylistWithQueue(void) if (!ob_synced()) return; - if (playlist.queued >= 0 && + if (player_errno != PLAYER_ERROR_NONE) { + DEBUG("playlist: error: %s\n", player_strerror()); + playlist.current = playlist.queued; + player_clearerror(); + } else if (playlist.queued >= 0 && playlist.current != playlist.queued) { DEBUG("playlist: now playing queued song\n"); DEBUG("%s:%d queued: %d\n",__func__,__LINE__,playlist.queued); -- cgit v1.2.3