(gl) Add check in gl_overlay_vertex_geom()

This commit is contained in:
Higor Eurípedes 2015-05-19 13:51:59 -03:00
parent dc5460effd
commit dfd6d464a8

View File

@ -2926,6 +2926,12 @@ static void gl_overlay_vertex_geom(void *data,
if (!gl)
return;
if (image > gl->overlays)
{
RARCH_ERR("Invalid overlay id: %u\n", image);
return;
}
vertex = (GLfloat*)&gl->overlay_vertex_coord[image * 8];
/* Flipped, so we preserve top-down semantics. */