]> git.sesse.net Git - vlc/blobdiff - modules/video_output/msw/glwin32.c
misc/objects.c: Don't rely on vlc_object_destroy() to destroy objects, but expects...
[vlc] / modules / video_output / msw / glwin32.c
index 45c2fbd913fffff6182d430ad0a37d915aba4c2d..f7eec90539503852818741d9aeccf2125aea21fa 100644 (file)
@@ -138,7 +138,7 @@ static int OpenVideo( vlc_object_t *p_this )
                            E_(EventThread), 0, 1 ) )
     {
         msg_Err( p_vout, "cannot create Vout EventThread" );
-        vlc_object_destroy( p_vout->p_sys->p_event );
+        vlc_object_release( p_vout->p_sys->p_event );
         p_vout->p_sys->p_event = NULL;
         goto error;
     }
@@ -237,7 +237,7 @@ static void CloseVideo( vlc_object_t *p_this )
         }
 
         vlc_thread_join( p_vout->p_sys->p_event );
-        vlc_object_destroy( p_vout->p_sys->p_event );
+        vlc_object_release( p_vout->p_sys->p_event );
     }
 
     vlc_mutex_destroy( &p_vout->p_sys->lock );