XML files in UTF-8 were broken by inserting variables if they "parsable". Non-latin chars become spoiled.
<pack id="server" name="Server" required="no" preselected="no">
<parsable type="xml" encoding="UTF-8" targetfile="$INSTALL_PATH/config/mainboard.xml"/>
But in result file:
How to make normal in current version 5.1.2:
<parsable type="java" encoding="ISO-8859-1" targetfile="$INSTALL_PATH/config/mainboard.xml"/>
Why ISO-8859-1??... I dont know but it works.
How I tried fix it in source code:
Looking to VariableSubstitutorInputStream. There is_ field private Reader substitutorReader;_
"Reader" is problematic here because we have:
public int read() throws IOException
Mixing of "Reader" and "InputStream" is not work well with different charsets.
java version "1.8.0_121"
Java(TM) SE Runtime Environment (build 1.8.0_121-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.121-b13, mixed mode)
I also was affected by this issue and sent a pull request that fixes it (adding also a couple of unit tests).
I hope to see this fix in the next version. Thank you.
Probably the same issue like ?