diff --git a/firmware/common/png_writer.cpp b/firmware/common/png_writer.cpp index 937e9d23..8a07326c 100644 --- a/firmware/common/png_writer.cpp +++ b/firmware/common/png_writer.cpp @@ -78,7 +78,7 @@ void PNGWriter::write_scanline(const std::array& scanline) constexpr uint32_t deflate_block_length = 1 + sizeof(scanline); const std::array deflate_and_scanline_header { - (scanline_count == (height - 1)) ? 0x01 : 0x00, // DEFLATE header bits, bfinal=0, btype=00 + static_cast((scanline_count == (height - 1)) ? 0x01 : 0x00), // DEFLATE header bits, bfinal=0, btype=00 static_cast((deflate_block_length >> 0) & 0xff), // Length LSB static_cast((deflate_block_length >> 8) & 0xff), // Length MSB static_cast((deflate_block_length >> 0) & 0xff) ^ 0xff, // ~Length LSB