Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/core
diff options
context:
space:
mode:
Diffstat (limited to 'source/core')
-rw-r--r--source/core/StarImage.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/core/StarImage.cpp b/source/core/StarImage.cpp
index 183b00a..f59765a 100644
--- a/source/core/StarImage.cpp
+++ b/source/core/StarImage.cpp
@@ -184,6 +184,8 @@ tuple<Vec2U, PixelFormat> Image::readPngMetadata(IODevicePtr device) {
channels += 1;
}
+ png_destroy_read_struct(&png_ptr, &info_ptr, &end_info);
+
Vec2U imageSize{img_width, img_height};
PixelFormat pixelFormat = channels == 3 ? PixelFormat::RGB24 : PixelFormat::RGBA32;