The short answer is that using read () and write () does not translate. [The answer to your question is no.]
A longer answer - read () and write () work in binary mode, which means that the content is considered βbinary dataβ. A \ n is ASCII 10 and 10 is a legitimate data value, which may, for example, represent the number 10.
This operation changing \ n to \ r \ n is a Windows problem. On Linux, the end of the line is simply marked \ n and no translation is required.
If you look at the manual page for fopen at http://linux.die.net/man/3/fopen , this paragraph is there
The mode string can also include the letter 'b' either as a last character or as a character between the characters in any of the two-character strings described above. This is strictly for compatibility with C89 and has no effect; the 'b' is ignored on all POSIX conforming systems, including Linux. (Other systems may treat text files and binary files differently, and adding the 'b' may be a good idea if you do I/O to a binary file and expect that your program may be ported to non-UNIX environments.)
Hope this helps.
source share