From 899fe982335f0ae33bbd0d5797480919423120ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Du=C5=A1an=20Poizl?= Date: Sun, 17 Mar 2024 14:14:03 +0100 Subject: [PATCH] Fix bug with writing ICCProfile --- libxisf.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libxisf.cpp b/libxisf.cpp index feef5c8..de6fd9e 100644 --- a/libxisf.cpp +++ b/libxisf.cpp @@ -1019,7 +1019,8 @@ void XISFWriterPrivate::writeImageElement(pugi::xml_node &node, const Image &ima if(image._iccProfile.size()) { ByteArray base64 = image._iccProfile; - base64.decodeBase64(); + base64.encodeBase64(); + base64.append('\0'); pugi::xml_node icc_node = image_node.append_child("ICCProfile"); icc_node.append_attribute("location").set_value("inline:base64"); icc_node.append_child(pugi::node_pcdata).set_value(base64.data());