mirror of
https://git.planet-casio.com/Lephenixnoir/gint.git
synced 2024-12-28 04:23:36 +01:00
render: add NULL alloc check to dpoly()
This commit is contained in:
parent
789ba7caa5
commit
5626713f40
1 changed files with 2 additions and 0 deletions
|
@ -10,6 +10,8 @@ static int compare(void const *ptr1, void const *ptr2)
|
|||
static void dpoly_fill(int const *x, int const *y, int N, int color)
|
||||
{
|
||||
int *nodeX = malloc(N * sizeof *nodeX);
|
||||
if(!nodeX)
|
||||
return;
|
||||
|
||||
/* Find vertical bounds */
|
||||
int ymin = y[0], ymax = y[0];
|
||||
|
|
Loading…
Reference in a new issue