From 6f16f0e910990d5c08d8586702c2118e555fa022 Mon Sep 17 00:00:00 2001 From: Bent Bisballe Nyeng Date: Sat, 31 Oct 2015 20:24:28 +0100 Subject: Fix 64 type problems with lodepng api. --- plugingui/image.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'plugingui') diff --git a/plugingui/image.cc b/plugingui/image.cc index fd79707..f2dfb9c 100644 --- a/plugingui/image.cc +++ b/plugingui/image.cc @@ -76,10 +76,14 @@ void Image::setError(int err) void Image::load(const char* data, size_t size) { + unsigned int iw, ih; unsigned int res = lodepng_decode32((unsigned char**)&image_data, - &_width, &_height, + &iw, &ih, (const unsigned char*)data, size); + _width = iw; + _height = ih; + if(res != 0) { ERR(image, "[read_png_file] Error during init_io"); -- cgit v1.2.3