Fixed another resource leak in the Image Manager 1024 code.

This commit is contained in:
OBattler
2020-01-14 23:10:03 +01:00
parent 84659f6b01
commit 7787c638bb

View File

@@ -527,7 +527,13 @@ hndl_poly(pgc_t *pgc)
}
while (parsing) {
if (! pgc_param_byte(pgc, &count)) return;
if (! pgc_param_byte(pgc, &count)) {
if (x)
free(x);
if (y)
free(y);
return;
}
if (count + realcount >= as) {
nx = (int32_t *)realloc(x, 2 * as * sizeof(int32_t));