I have xml-flie with such structure for my app update metadata on server:
<?xml version="1.0" encoding="windows-1251"?>
As you notice, this file has custom encoding specification (<?xml version="1.0" encoding="windows-1251"?>
), but xml notepad doesn't check on exit that this file contains simbols with different codepage (e.g. Unicode),
which causes bugs on my server.
Can you add encoding validation?
You can check this bug, for example, by copying date from some external source and inserting it in this file opened in xml notepad.
P.S. xml-file system encoding is correct - non unicode!
I attached erroneous xml-file with incorrect encoding symbols in tag <date>.