[vlc-devel] [vlc-commits] vout: remove dead code

Steve Lhomme robux4 at ycbcr.xyz
Thu May 9 15:52:07 CEST 2019


This commit make VLC crash with "--vout=none"

It assert in vout_Release() on "assert(!sys->window_active);"

After commit a1924dbd8bb3e3c146ef150191dcf8ffa0be0a59 "resource: 
atomically return vout on failure (fixes #22284)" it's not an assert 
anymore. It's a hard crash. vout_Request() is called with cfg->vout NULL.



On 2019-05-08 20:21, Rémi Denis-Courmont wrote:
> vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Wed May  8 18:54:01 2019 +0300| [587a5e2ac478b151848c06a55b1c9f7960f272de] | committer: Rémi Denis-Courmont
> 
> vout: remove dead code
> 
> If the vout was not stopped explicitly, vout_Close() will call
> vout_Stop() anyway. Either way, the window is necessarily disabled when
> the last reference to the vout is dropped.
> 
>> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=587a5e2ac478b151848c06a55b1c9f7960f272de
> ---
> 
>   src/video_output/video_output.c | 3 +--
>   1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
> index 27a269e9d9..ce7ca69b83 100644
> --- a/src/video_output/video_output.c
> +++ b/src/video_output/video_output.c
> @@ -1715,8 +1715,7 @@ void vout_Release(vout_thread_t *vout)
>       vlc_mutex_destroy(&vout->p->spu_lock);
>       vlc_mutex_destroy(&vout->p->filter.lock);
>   
> -    if (sys->window_active)
> -        vout_window_Disable(sys->display_cfg.window);
> +    assert(!sys->window_active);
>       vout_display_window_Delete(sys->display_cfg.window);
>   
>       vout_control_Clean(&vout->p->control);
> 
> _______________________________________________
> vlc-commits mailing list
> vlc-commits at videolan.org
> https://mailman.videolan.org/listinfo/vlc-commits
> 


More information about the vlc-devel mailing list