Fixed memory leak.
This commit is contained in:
parent
17bd80329a
commit
011d60ec03
@ -4585,7 +4585,8 @@ static int gluBuild2DMipmapLevelsCore(GLenum target, GLint internalFormat,
|
|||||||
glPixelStorei(GL_UNPACK_ROW_LENGTH, psm.unpack_row_length);
|
glPixelStorei(GL_UNPACK_ROW_LENGTH, psm.unpack_row_length);
|
||||||
glPixelStorei(GL_UNPACK_SWAP_BYTES, psm.unpack_swap_bytes);
|
glPixelStorei(GL_UNPACK_SWAP_BYTES, psm.unpack_swap_bytes);
|
||||||
#endif
|
#endif
|
||||||
free(dstImage);
|
if (srcImage) free(srcImage);
|
||||||
|
if (dstImage) free(dstImage);
|
||||||
return GLU_OUT_OF_MEMORY;
|
return GLU_OUT_OF_MEMORY;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user