mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-29 00:23:23 -05:00
[queue] If the playing item is not in the queue anymore, the next item
should be the first item in the queue This solves the problem that after clearing the queue and adding new items while playing, aborts playback when skipped to the next item.
This commit is contained in:
parent
abc689a7e1
commit
7b5c80acf4
@ -460,8 +460,8 @@ queue_next(struct queue *queue, unsigned int item_id, char shuffle, enum repeat_
|
|||||||
item = queueitem_get_byitemid(queue, item_id);
|
item = queueitem_get_byitemid(queue, item_id);
|
||||||
|
|
||||||
if (!item)
|
if (!item)
|
||||||
// Item not found
|
// Item not found, start playing from the start of the queue
|
||||||
return NULL;
|
item = queue->head;
|
||||||
|
|
||||||
if (r_mode == REPEAT_SONG && item != queue->head)
|
if (r_mode == REPEAT_SONG && item != queue->head)
|
||||||
return item;
|
return item;
|
||||||
|
Loading…
Reference in New Issue
Block a user