in reply to Re: regex to add network line-endings if required.
in thread regex to add network line-endings if required.
"platform specific line-ending" could be "\012" ("\l") for Unix, "\015\012" ("\r\l") or "\012\015" ("\l\r") for DOS, or "\015" ("\r") for at least older Macs. All of these, on their own platforms, are represented by the C library as "\n" (newline).
"Network line-ending" means "\015\012", which is the standard for things like Telnet and HTTP.
Any telnet or web implementation on any platform uses "\015\012" (carriage return followed by linefeed) as the end-of-line marker.
See RFC 1945 for HTTP and RFC 854 (STD 0008) for Telnet for examples.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: regex to add network line-endings if required.
by ww (Archbishop) on Feb 15, 2005 at 17:52 UTC |