Menu

#536 ed cannot properly handle CRLF line endings

Ed
open
nobody
None
5
2012-07-26
2011-03-19
Dan N
No

Note that the help text displayed in response to ed --help says that there is a --textmode option to enable CRLF line endings, but when I attempt to use this option, the error message "ed: internal_error: uncaught option" results. The behavior when I edit a regular Windows text file is existing lines retain their CRLF line endings, while newly added lines get LF-only endings. The CR characters at the ends of existing lines are displayed as "\r" on line endings when the 'l' command is used to list lines.

Discussion