From 0330f713eeedd07567643bc835f34910ac2d6d6d Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 13 Jan 1999 21:26:15 +0000 Subject: [PATCH] compilation problem fixed git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1400 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/image.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/image.cpp b/src/common/image.cpp index cfceb4dc1c..0b4a2fdca7 100644 --- a/src/common/image.cpp +++ b/src/common/image.cpp @@ -493,6 +493,7 @@ bool wxPNGHandler::LoadFile( wxImage *image, wxInputStream& stream ) // method is to use goto (setjmp is not really C++ dtors friendly...) unsigned char **lines = (unsigned char **) NULL; + unsigned int i; png_infop info_ptr = (png_infop) NULL; image->Destroy(); @@ -540,7 +541,7 @@ bool wxPNGHandler::LoadFile( wxImage *image, wxInputStream& stream ) if (lines == NULL) goto error; - for (unsigned int i = 0; i < height; i++) + for (i = 0; i < height; i++) { if ((lines[i] = (unsigned char *)malloc(width * (sizeof(unsigned char) * 4))) == NULL) { -- 2.45.2