On Sun Nov 20 15:22:06 2022 +0000, David Kahurani wrote:
Write_escaped_string with explicit length basically writes everything including the terminating `'\0'` which gets rejected by writer_get_next_count with WC_E_XMLCHARACTER basically achieving the same result. In the case of WriteRaw() and WriteRawChars() the terminating `'\0'` never actually gets written. I check both *pwch and cwch because we are writing a particular number of characters which yes, might equal the characters in the string or may not be equal. Edit : Checking for *pwch allows us to catch a possible error where user tried to write more characters than are in the provided string
Uhhmm... Okay, I see where you're coming from. Just checking for cwch will achieve the same result, yes. Will update the code to just check for cwch.