[vlc-commits] playlist: ignore input state event
Rémi Denis-Courmont
git at videolan.org
Sun Nov 5 09:11:37 CET 2017
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Nov 5 09:39:22 2017 +0200| [06ce5bd0ac1b605880495b7143f453aa31c36a04] | committer: Rémi Denis-Courmont
playlist: ignore input state event
Any started input will eventually emit the dead event if/when it ends.
There are no needs to track the state event separately.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=06ce5bd0ac1b605880495b7143f453aa31c36a04
---
src/playlist/thread.c | 17 +++++++----------
1 file changed, 7 insertions(+), 10 deletions(-)
diff --git a/src/playlist/thread.c b/src/playlist/thread.c
index 076260fb29..8f1ad96821 100644
--- a/src/playlist/thread.c
+++ b/src/playlist/thread.c
@@ -97,16 +97,13 @@ static int InputEvent( vlc_object_t *p_this, char const *psz_cmd,
VLC_UNUSED(p_this); VLC_UNUSED(psz_cmd); VLC_UNUSED(oldval);
playlist_t *p_playlist = p_data;
- if( newval.i_int != INPUT_EVENT_STATE &&
- newval.i_int != INPUT_EVENT_DEAD )
- return VLC_SUCCESS;
-
- PL_LOCK;
-
- /* XXX: signaling while not changing any parameter... suspicious... */
- vlc_cond_signal( &pl_priv(p_playlist)->signal );
-
- PL_UNLOCK;
+ if( newval.i_int == INPUT_EVENT_DEAD )
+ {
+ PL_LOCK;
+ /* XXX: signaling while not changing any parameter... suspicious... */
+ vlc_cond_signal( &pl_priv(p_playlist)->signal );
+ PL_UNLOCK;
+ }
return VLC_SUCCESS;
}
More information about the vlc-commits
mailing list