shader_glsl.c: Move buffer null pointer check in gl_glsl_set_coords()

`buffer` is initialized to a statically allocated variable and can only be NULL
when the allocation of a bigger buffer fails. When only the core frame is being
displayed, the buffer never points to the heap thanks to the small buffer
optimization.
This commit is contained in:
Higor Eurípedes 2020-06-06 17:26:42 -03:00
parent 9dca8de90f
commit 1f45018ee8
1 changed files with 3 additions and 3 deletions

View File

@ -1443,10 +1443,10 @@ static bool gl_glsl_set_coords(void *shader_data,
elems *= coords->vertices * sizeof(GLfloat);
buffer = (GLfloat*)malloc(elems);
}
if (!buffer)
return false;
if (!buffer)
return false;
}
if (uni->tex_coord >= 0)
{