summaryrefslogtreecommitdiff
path: root/src/glu/sgi/libutil
diff options
context:
space:
mode:
authorVinson Lee <vlee@vmware.com>2009-11-25 00:18:49 -0500
committerVinson Lee <vlee@vmware.com>2009-11-25 00:18:49 -0500
commitf895abbd9777c4985aa40cf660c68f6d7333f0ec (patch)
tree4338d8ab859ab9f9b0fa5d314a622d8183e70b18 /src/glu/sgi/libutil
parentf1ce37f74aff4854071fe5740b055718b2c0c789 (diff)
glu/sgi: Fix memory leak in gluBuild3DMipmapLevelsCore.
Diffstat (limited to 'src/glu/sgi/libutil')
-rw-r--r--src/glu/sgi/libutil/mipmap.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/glu/sgi/libutil/mipmap.c b/src/glu/sgi/libutil/mipmap.c
index a5d07a59cf..22d702291f 100644
--- a/src/glu/sgi/libutil/mipmap.c
+++ b/src/glu/sgi/libutil/mipmap.c
@@ -8098,6 +8098,7 @@ static int gluBuild3DMipmapLevelsCore(GLenum target, GLint internalFormat,
glPixelStorei(GL_UNPACK_SWAP_BYTES, psm.unpack_swap_bytes);
glPixelStorei(GL_UNPACK_SKIP_IMAGES, psm.unpack_skip_images);
glPixelStorei(GL_UNPACK_IMAGE_HEIGHT, psm.unpack_image_height);
+ free(srcImage);
return GLU_OUT_OF_MEMORY;
}
/* level userLevel+1 is in srcImage; level userLevel already saved */