src/XMLDocumentConstructor.h
branchv_0
changeset 13 d5e2cb9e31f1
parent 10 6904e4448807
child 40 85b6f13f1088
--- a/src/XMLDocumentConstructor.h	Sun Jun 20 10:23:50 2021 +0200
+++ b/src/XMLDocumentConstructor.h	Sun Jun 20 20:16:46 2021 +0200
@@ -17,6 +17,7 @@
 #pragma once
 
 #include <memory>
+#include <stdexcept>
 
 #include <libxml++-2.6/libxml++/libxml++.h>
 
@@ -53,7 +54,7 @@
 
 		try {
 			// TODO: buffering? (reader itself also buffers)
-			for (char ch = input->get(); input->good(); ch = input->get()) reader.write(&ch, 1);
+			for (uint8_t b = input->get(); input->good(); b = input->get()) reader.write(&b, 1);
 		} catch (const relpipe::in::asn1::lib::TransactionalBuffer::WriteBufferOverflowException& e) {
 			// TODO: avoid leaky abstraction and use different exception
 			throw relpipe::writer::RelpipeWriterException(L"Transactional buffer for ASN.1 input is too small");