summaryrefslogtreecommitdiff
path: root/plugingui
diff options
context:
space:
mode:
Diffstat (limited to 'plugingui')
-rw-r--r--plugingui/image.cc6
-rw-r--r--plugingui/image.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/plugingui/image.cc b/plugingui/image.cc
index ecd16ac..52c5c9f 100644
--- a/plugingui/image.cc
+++ b/plugingui/image.cc
@@ -52,7 +52,7 @@ Image::~Image()
free(image_data);
}
-void Image::setError(int err)
+void Image::setError()
{
Resource rc(":png_error");
@@ -86,8 +86,8 @@ void Image::load(const char* data, size_t size)
if(res != 0)
{
- ERR(image, "[read_png_file] Error during init_io");
- setError(3);
+ ERR(image, "Error in lodepng_decode32: %d", res);
+ setError();
return;
}
}
diff --git a/plugingui/image.h b/plugingui/image.h
index 791ade4..0decc22 100644
--- a/plugingui/image.h
+++ b/plugingui/image.h
@@ -45,7 +45,7 @@ public:
Colour getPixel(size_t x, size_t y) const;
private:
- void setError(int err);
+ void setError();
void load(const char* data, size_t size);