Text files are organized differently on unix or Windows/DOS. On unix, the line endings are marked with a single <newline> character (NL resp. "\n"), on Windows with a <return><newline> sequence (CR/NL resp "\r\n"). A decent text editor on both sides will have no problems with that, and will display a file correctly, assuming that all lines in the file use one convention consistently.
A less decent text editor on unix will display the <return> characters as "^M" ("<control>M" is the convention for most unix terminals to enter the ASCII value of 0x0D). A less decent editor on Windows will display a file in unix convention all on one line, with something garbled where the lines were meant to break. Btw: To add to the confusion, on the traditional Mac systems, line endings were marked with a <return> character alone, but I think that OS-X is leaning more towards the unix conventions.
Solution? Get a decent text editor! On Windows, Wordpad does nicely, on unix (and elsewhere) I use vim myself, but that may not be suitable for the faint of heart... ;). I'm sure there are many other decent editors, just shop around. Of course, if one file mixes several conventions on seperate lines, then there's no solution. Such a file is simply broken.
Thanks bird for your help. We have decided to filter out from the data all these redundant \r\n characters to solve the problem of mixed special characters. Otherwise it would come back on us every time we want to reuse the data in windows...