vlc | branch: master | Mark Lee <[email protected]> | Mon Apr 20 10:51:26 2020 +0100| [11c47c1b5f876b00da4d78425dc1bd60507a91c9] | committer: Thomas Guillem
lib: lock the player before updating the viewpoint Signed-off-by: Thomas Guillem <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=11c47c1b5f876b00da4d78425dc1bd60507a91c9 --- lib/video.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/video.c b/lib/video.c index 6f8e6d7f59..4e12fbafa1 100644 --- a/lib/video.c +++ b/lib/video.c @@ -274,7 +274,13 @@ int libvlc_video_update_viewpoint( libvlc_media_player_t *p_mi, enum vlc_player_whence whence = b_absolute ? VLC_PLAYER_WHENCE_ABSOLUTE : VLC_PLAYER_WHENCE_RELATIVE; - vlc_player_UpdateViewpoint(p_mi->player, &update, whence); + + vlc_player_t *player = p_mi->player; + vlc_player_Lock(player); + + vlc_player_UpdateViewpoint(player, &update, whence); + + vlc_player_Unlock(player); /* may not fail anymore, keep int not to break the API */ return 0; _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
