From ceae86899da8c7308e0fe362dd6ff3b1473d05e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luis=20D=C3=ADaz=20M=C3=A1s?= Date: Thu, 6 Jan 2022 18:21:26 +0100 Subject: [PATCH] Initialize uninitialized variables --- src/pngimage.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/pngimage.cpp b/src/pngimage.cpp index 1e2cf6dc..befaa3b6 100644 --- a/src/pngimage.cpp +++ b/src/pngimage.cpp @@ -92,7 +92,7 @@ namespace Exiv2 { } } } - } // PngImage::PngImage + } std::string PngImage::mimeType() const { @@ -102,7 +102,7 @@ namespace Exiv2 { static bool zlibToDataBuf(const byte* bytes,long length, DataBuf& result) { uLongf uncompressedLen = length * 2; // just a starting point - int zlibResult; + int zlibResult = Z_BUF_ERROR; do { result.alloc(uncompressedLen); @@ -130,7 +130,7 @@ namespace Exiv2 { static bool zlibToCompressed(const byte* bytes,long length, DataBuf& result) { uLongf compressedLen = length; // just a starting point - int zlibResult; + int zlibResult = Z_BUF_ERROR; do { result.alloc(compressedLen);