[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Text tools, line endings, and O_TEXT
From: |
John Cowan |
Subject: |
Text tools, line endings, and O_TEXT |
Date: |
Thu, 6 Sep 2007 10:00:58 -0400 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
Eric Blake scripsit:
> If you disagree with the cygwin philosophy, or with the particular
> implementation of that philosophy as embodied by ptx, you are better
> off raising the issue on the cygwin mailing lists rather than here.
I don't in fact disagree with it; I was simply clarifying the OP's
situation (which appeared only in the Subject: line).
> This argument, on the other hand, is appropriate to bring up here, as you
> are claiming that ptx's behavior should be able to (optionally) ignore \r
> on all platforms.
Indeed, I'd like to see all text tools accept all six known line ending
conventions: CR+LF, CR alone, LF alone, NEL alone, CR+NEL, LS.
(NEL is U+0085, LS is U+2028.)
> In which case, Jim's proposed patch of adding O_TEXT is
> inappropriate on two counts - it will not affect Linux (while you argued
> that Linux should also have a way to ignore \r), and it will make the
> default behavior of a cygwin binary mount diverge from behavior of Linux
> (which goes counter to cygwin's goal of behaving like Linux when used on
> binary mounts).
Are you saying that an O_TEXT open under Cygwin, given a binary mount,
will cause newline translation? I had assumed that O_TEXT would be
ignored under Cygwin just as it is under Linux.
That said, I believe it is good for portability to use O_TEXT
and O_BINARY (and their stdio equivalents) in all software intended
to be portable. Unix-tradition systems won't benefit, but it doesn't
cost anything either; other systems will be enabled to DTRT as a result.
--
Even the best of friends cannot John Cowan
attend each others' funeral. address@hidden
--Kehlog Albran, The Profit http://www.ccil.org/~cowan
- Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, Graig, 2007/09/05
- Re: Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, Bob Proulx, 2007/09/05
- Re: Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, John Cowan, 2007/09/05
- Re: Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, Bob Proulx, 2007/09/06
- Re: Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, Eric Blake, 2007/09/06
- Re: Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, Jim Meyering, 2007/09/06
- Text tools, line endings, and O_TEXT,
John Cowan <=
- Re: Text tools, line endings, and O_TEXT, Eric Blake, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, Micah Cowan, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, Eric Blake, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, John Cowan, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, Eric Blake, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, John Cowan, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, Micah Cowan, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, John Cowan, 2007/09/06
- Re: Text tools, line endings, and O_TEXT, Bob Proulx, 2007/09/06
Re: Problem with -i ignore-file option in version 6.9 ptx in cygwin environment, Jim Meyering, 2007/09/06