About line break in XML

I ma using Xerces library, when i writing a xml file, the line break is '/r/n', but if i read it in again, it is only '/n' there.
Is this the XML standard?
There is a description about it from W3C http://www.w3.org/TR/2000/REC-xml-20001006#sec-line-ends.

2.11 End-of-Line Handling

XML parsed entities are often stored in computer files which, for editing convenience, are organized into lines. These lines are typically separated by some combination of the characters carriage-return (#xD) and line-feed (#xA).

To simplify the tasks of applications, the characters passed to an application by the XML processor must be as if the XML processor normalized all line breaks in external parsed entities (including the document entity) on input, before parsing, by translating both the two-character sequence #xD #xA and any #xD that is not followed by #xA to a single #xA character.

Does that mean there would be only \n be used in xml from end line handling?
Thanks.
What OS are you running on? And does the behavior change when you use a different OS?

newline (\n) is the line delimiter on Unix. carriage return + newline (\r\n) is the line delimiter on Windows. And Mac uses (used?) newline + carriage return IIRC.

Have fun.
I am using Windows XP now, and i haven't tried it on Mac yet.

According to the description i posted, looks like it is the XML standard, right?
Topic archived. No new replies allowed.