[vlc-devel] [PATCH 1/3] vout: move mutex destroy after window delete
    Thomas Guillem 
    thomas at gllm.fr
       
    Fri Nov  8 11:56:15 CET 2019
    
    
  
This will be needed by next commits, since the window_lock will be held from
window plugin events.
Refs #22674
---
 src/video_output/video_output.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index dc093e5f959..3d2d78f6f23 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -1803,10 +1803,6 @@ void vout_Release(vout_thread_t *vout)
 
     free(sys->splitter_name);
 
-    /* Destroy the locks */
-    vlc_mutex_destroy(&sys->window_lock);
-    vlc_mutex_destroy(&sys->filter.lock);
-
     if (sys->dec_device)
         vlc_decoder_device_Release(sys->dec_device);
 
@@ -1814,6 +1810,10 @@ void vout_Release(vout_thread_t *vout)
     vout_display_window_Delete(sys->display_cfg.window);
 
     vout_control_Clean(&sys->control);
+
+    /* Destroy the locks */
+    vlc_mutex_destroy(&sys->window_lock);
+    vlc_mutex_destroy(&sys->filter.lock);
     vlc_mutex_destroy(&sys->display_lock);
 
     /* */
-- 
2.20.1
    
    
More information about the vlc-devel
mailing list