1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-29 10:32:15 +00:00

player: prevent null pointer deref on uninit after -V

Caused by the OSD changes. Fixes #490.
This commit is contained in:
wm4 2014-01-18 17:59:34 +01:00
parent 8cbed35403
commit 03859a581c

View File

@ -2448,6 +2448,8 @@ static void overlay_remove(struct MPContext *mpctx, int id)
static void overlay_uninit(struct MPContext *mpctx)
{
if (!mpctx->osd)
return;
for (int id = 0; id < OVERLAY_MAX_ID; id++)
overlay_remove(mpctx, id);
osd_set_external2(mpctx->osd, NULL);