vo_gl: fix crash with backends lacking control() features
commitb200583403219136363b755afab2b05c0937a928
authorwm4 <wm4@mplayer2.org>
Mon, 24 Oct 2011 02:51:24 +0000 (24 04:51 +0200)
committerUoti Urpala <uau@mplayer2.org>
Mon, 24 Oct 2011 05:36:17 +0000 (24 08:36 +0300)
treee828b37713b14ac7a6d24cdc0a1c5abced133415
parent2123bff6fa24d43dfc5768ddc0ca855819f0b1b0
vo_gl: fix crash with backends lacking control() features

Some functionality provided by the windowing backend (such as x11,
win32) is optional. The function pointers in MPGLContext are NULL if
the functionality is not implemented. Check them before calling them,
instead of crashing. This happened at least on Windows with the
"vo_ontop" command.
libvo/vo_gl.c