queue/PlaylistControl: fix return value in PlayNext(), PlayPrevious()

Failure must be indicated by returning false.
This commit is contained in:
Max Kellermann 2016-09-05 19:21:23 +02:00
parent 871063dab7
commit a71efacd1e

View File

@ -124,7 +124,7 @@ playlist::PlayNext(PlayerControl &pc, Error &error)
if (!playing) {
error.Set(playlist_domain, int(PlaylistResult::NOT_PLAYING),
"Not playing");
return true;
return false;
}
assert(!queue.IsEmpty());
@ -176,7 +176,7 @@ playlist::PlayPrevious(PlayerControl &pc, Error &error)
if (!playing) {
error.Set(playlist_domain, int(PlaylistResult::NOT_PLAYING),
"Not playing");
return true;
return false;
}
assert(!queue.IsEmpty());