Hi Paul, On Feb 12, 2015, at 4:37 AM, Paul Sandoz <paul.san...@oracle.com> wrote:
> What do existing XML APIs do? This is a morass and I hope that someone more apt to know it well would comment. The U+0000 null control character is always illegal though I do know that. > My guess from looking at your webrev APIs such as DOM allow such invalid > characters when writing and reading? If so that would seem to be more of a > fundamental issue with those APIs and not specifically with preferences. I tend to agree where the DOM does allow the characters: they should be handled. > I think there should be an error if a key or value contains a the U+0000 > character when writing out the set of property entries to XML, otherwise it > just propagates the error to who or what is consuming that XML file. The problem is that on OSX and Windows prefs are not stored to XML whereas on Unix they are. That would make it an error to add such a value to the prefs on some platforms but not on others. Thanks, Brian