projects
/
profile
/
ivi
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d3b4c99
)
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>
Sun, 22 Nov 2009 06:57:35 +0000
(
01:57
-0500)
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
af647af
..
4139c30
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;
}