mirror of
https://github.com/owntone/owntone-server.git
synced 2025-03-31 01:33:44 -04:00
Properly stop playback if playback cannot start to reset player state
If the playback cannot start for a reason of another, the player state needs to be reset by calling playback_stop().
This commit is contained in:
parent
d9f5e2aa40
commit
7d480faecd
@ -1783,6 +1783,7 @@ playback_start(void *arg)
|
|||||||
{
|
{
|
||||||
DPRINTF(E_LOG, L_PLAYER, "Couldn't jump to queue position %d\n", *idx_id);
|
DPRINTF(E_LOG, L_PLAYER, "Couldn't jump to queue position %d\n", *idx_id);
|
||||||
|
|
||||||
|
playback_stop(NULL);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1800,6 +1801,7 @@ playback_start(void *arg)
|
|||||||
{
|
{
|
||||||
DPRINTF(E_LOG, L_PLAYER, "Couldn't find anything to play!\n");
|
DPRINTF(E_LOG, L_PLAYER, "Couldn't find anything to play!\n");
|
||||||
|
|
||||||
|
playback_stop(NULL);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1815,6 +1817,7 @@ playback_start(void *arg)
|
|||||||
{
|
{
|
||||||
DPRINTF(E_LOG, L_PLAYER, "Could not open local audio\n");
|
DPRINTF(E_LOG, L_PLAYER, "Could not open local audio\n");
|
||||||
|
|
||||||
|
playback_stop(NULL);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1845,6 +1848,7 @@ playback_start(void *arg)
|
|||||||
{
|
{
|
||||||
DPRINTF(E_LOG, L_PLAYER, "Could not start playback: no output selected or couldn't start any output\n");
|
DPRINTF(E_LOG, L_PLAYER, "Could not start playback: no output selected or couldn't start any output\n");
|
||||||
|
|
||||||
|
playback_stop(NULL);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user