[vlc-commits] playlist: only exit after actually playing (fixes #18992)
Rémi Denis-Courmont
git at videolan.org
Sun Nov 5 09:11:41 CET 2017
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Nov 5 10:08:39 2017 +0200| [b4e127ead0bd7a767e1a521218f0ff14eb124996] | committer: Rémi Denis-Courmont
playlist: only exit after actually playing (fixes #18992)
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b4e127ead0bd7a767e1a521218f0ff14eb124996
---
src/playlist/thread.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/playlist/thread.c b/src/playlist/thread.c
index e37d70533a..9f51054089 100644
--- a/src/playlist/thread.c
+++ b/src/playlist/thread.c
@@ -473,6 +473,7 @@ static void *Thread ( void *data )
{
playlist_t *p_playlist = data;
playlist_private_t *p_sys = pl_priv(p_playlist);
+ bool played = false;
PL_LOCK;
while( !p_sys->killed )
@@ -488,11 +489,14 @@ static void *Thread ( void *data )
/* Playlist in running state */
while( !p_sys->killed && Next( p_playlist ) )
+ {
LoopInput( p_playlist );
+ played = true;
+ }
/* Playlist stopping */
msg_Dbg( p_playlist, "nothing to play" );
- if( var_InheritBool( p_playlist, "play-and-exit" ) )
+ if( played && var_InheritBool( p_playlist, "play-and-exit" ) )
{
msg_Info( p_playlist, "end of playlist, exiting" );
libvlc_Quit( p_playlist->obj.libvlc );
More information about the vlc-commits
mailing list