projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d23bb22
)
glu/sgi: Fix memory leak in gluScaleImage.
author
Vinson Lee
<vlee@vmware.com>
Sun, 22 Nov 2009 06:57:35 +0000
(
01:57
-0500)
committer
Vinson Lee
<vlee@vmware.com>
Fri, 4 Dec 2009 08:09:22 +0000
(
00:09
-0800)
(cherry picked from commit
a9c540f5dedbf593f8038fdbc95eecb60826ab26
)
src/glu/sgi/libutil/mipmap.c
patch
|
blob
|
history
diff --git
a/src/glu/sgi/libutil/mipmap.c
b/src/glu/sgi/libutil/mipmap.c
index af647af73c98cbc1bda3e61835a01a82142050a1..4139c304a1dfaf11d21a12340d49c9b99b5284c2 100644
(file)
--- a/
src/glu/sgi/libutil/mipmap.c
+++ b/
src/glu/sgi/libutil/mipmap.c
@@
-3526,6
+3526,8
@@
gluScaleImage(GLenum format, GLsizei widthin, GLsizei heightin,
afterImage =
malloc(image_size(widthout, heightout, format, GL_UNSIGNED_SHORT));
if (beforeImage == NULL || afterImage == NULL) {
+ free(beforeImage);
+ free(afterImage);
return GLU_OUT_OF_MEMORY;
}