[vlc-commits] vout: disable window when vout_Start() fails

Thomas Guillem git at videolan.org
Thu May 9 17:16:58 CEST 2019


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Thu May  9 16:11:36 2019 +0200| [f8bdf7325aa5939ce7ee80bfea2d8ef28743f02e] | committer: Thomas Guillem

vout: disable window when vout_Start() fails

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=f8bdf7325aa5939ce7ee80bfea2d8ef28743f02e
---

 src/video_output/video_output.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index b84336ac23..ea1d90705a 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -1878,7 +1878,13 @@ int vout_Request(const vout_configuration_t *cfg, input_thread_t *input)
     vlc_mutex_unlock(&sys->window_lock);
 
     if (vout_Start(vout, cfg))
+    {
+        vlc_mutex_lock(&sys->window_lock);
+        vout_window_Disable(sys->display_cfg.window);
+        sys->window_active = false;
+        vlc_mutex_unlock(&sys->window_lock);
         goto error;
+    }
     if (vlc_clone(&sys->thread, Thread, vout, VLC_THREAD_PRIORITY_OUTPUT)) {
         vout_Stop(vout);
 error:



More information about the vlc-commits mailing list