[vlc-devel] [PATCH 2/6] opengl: ensure opengl context is current

Rémi Denis-Courmont remi at remlab.net
Thu Jan 28 18:03:14 UTC 2021


Le torstaina 28. tammikuuta 2021, 18.57.40 EET Alexandre Janniaux a écrit :
> ---
>  modules/video_output/opengl/display.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/modules/video_output/opengl/display.c
> b/modules/video_output/opengl/display.c index d95ce8fb6e..62b159aa47 100644
> --- a/modules/video_output/opengl/display.c
> +++ b/modules/video_output/opengl/display.c
> @@ -193,7 +193,8 @@ static void Close(vout_display_t *vd)
>      vout_display_sys_t *sys = vd->sys;
>      vlc_gl_t *gl = sys->gl;
> 
> -    vlc_gl_MakeCurrent (gl);
> +    int ret = vlc_gl_MakeCurrent (gl);
> +    assert(ret == VLC_SUCCESS);
>      vout_display_opengl_Delete (sys->vgl);
>      vlc_gl_ReleaseCurrent (gl);

No objections as this is no new problem, but this type of construct makes 
compilers unhappy in release builds.

-- 
Реми Дёни-Курмон
http://www.remlab.net/





More information about the vlc-devel mailing list