aboutsummaryrefslogtreecommitdiff
path: root/graphics/decoders
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/decoders')
-rw-r--r--graphics/decoders/png.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/graphics/decoders/png.cpp b/graphics/decoders/png.cpp
index 4f917b44b1..11e26162eb 100644
--- a/graphics/decoders/png.cpp
+++ b/graphics/decoders/png.cpp
@@ -227,7 +227,7 @@ bool PNGDecoder::loadStream(Common::SeekableReadStream &stream) {
png_read_end(pngPtr, NULL);
// Destroy libpng structures
- png_destroy_read_struct(&pngPtr, &infoPtr, NULL);
+ png_destroy_read_struct(&pngPtr, &infoPtr, &endInfo);
// We no longer need the file stream, thus close it here
_stream = 0;