0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 12:02:23 +02:00

vo_opengl_cb: avoid NULL pointer deref in corner cases

Found by Coverity.
This commit is contained in:
wm4 2015-12-05 23:53:41 +01:00
parent 791228f2ab
commit 63204eda5d

View File

@ -269,7 +269,8 @@ int mpv_opengl_cb_draw(mpv_opengl_cb_context *ctx, int fbo, int vp_w, int vp_h)
struct vo_priv *opts = ctx->new_opts ? ctx->new_opts : p;
if (opts) {
gl_video_set_options(ctx->renderer, opts->renderer_opts);
gl_video_configure_queue(ctx->renderer, vo);
if (vo)
gl_video_configure_queue(ctx->renderer, vo);
ctx->gl->debug_context = opts->use_gl_debug;
gl_video_set_debug(ctx->renderer, opts->use_gl_debug);
}