stb: ++safety.

make it safe not to leave potential dangling pointers.
This commit is contained in:
Hermet Park
2019-07-09 21:37:59 +09:00
parent 5888aa5bfa
commit 9be18fbd40

View File

@@ -4580,6 +4580,7 @@ static int stbi__create_png_image(stbi__png *a, stbi_uc *image_data, stbi__uint3
}
}
STBI_FREE(a->out);
a->out = NULL;
image_data += img_len;
image_data_len -= img_len;
}