diff options
author | Eric Anholt <eric@anholt.net> | 2009-07-02 14:04:40 -0700 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2009-07-02 14:04:40 -0700 |
commit | 8532eca1681e222084ef2730506523187e99a33e (patch) | |
tree | ac014a4620772695a61d97921b477b5b39fb6dd4 | |
parent | 0f5e3969b957f71315104ab6814338f8c84d66f4 (diff) |
Don't leak the libpng structures.
-rw-r--r-- | load_texture.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/load_texture.c b/load_texture.c index b191a57..d83d0ef 100644 --- a/load_texture.c +++ b/load_texture.c @@ -124,5 +124,7 @@ GLuint load_texture_rgb(const char *filename) free(data); free(row_pointers); + png_destroy_read_struct(&png, &png_info, NULL); + return tex; } |