diff options
author | Vinson Lee <vlee@vmware.com> | 2009-11-17 13:49:31 -0800 |
---|---|---|
committer | Vinson Lee <vlee@vmware.com> | 2009-11-17 13:49:31 -0800 |
commit | d9508e8df9da4aa13bc223194c406081738bac91 (patch) | |
tree | a46e170bdb3e97c1fa38762acb1927c40db3e95b /progs/util | |
parent | 8c5a108dc321c4760e6d70b1104493b5bd54e6de (diff) |
progs/util: Fix memory leak if fopen fails in RawImageOpen.
Diffstat (limited to 'progs/util')
-rw-r--r-- | progs/util/readtex.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/progs/util/readtex.c b/progs/util/readtex.c index c57b66bd9d..3922998fd5 100644 --- a/progs/util/readtex.c +++ b/progs/util/readtex.c @@ -109,6 +109,7 @@ static rawImageRec *RawImageOpen(const char *fileName) raw->file = fopen(baseName + 1, "rb"); if(raw->file == NULL) { perror(fileName); + free(raw); return NULL; } } |