[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Regression -- can't read input w/stderr redirect
From: |
L A Walsh |
Subject: |
Re: Regression -- can't read input w/stderr redirect |
Date: |
Sun, 18 Jun 2017 15:59:40 -0700 |
User-agent: |
Thunderbird |
Chet Ramey wrote:
Bash has always stripped NULL bytes. Now it tells you it's doing it.
Why? Did I toggle a flag asking for the warning? Seems like it
was sorta sprung on users w/no way to disable it.
Side question: Why display that message if there are only
NUL's at the end? I would think it normal for bash to
use and read NUL terminated strings.
This is very uncommon. Most Unix utilities use newline-terminated
lines.
----
But things are changing -- people have asked for zero-terminated read's
and readarrays. More unix utils are offering NUL termination as an option
because newlines alone don't cut it in some instances.
Also, Bash is being used on windows: in cygwin and natively.
It's not uncommon for NUL's to be in input on windows --
its VERY common if you read something from the registry (as I've
done for over a decade), or if you read something with UTF-16
in it as I just tried to do. Bash mangles the locale's strings.
In UTF-16, 0x0000 (16-bits) of zero are an eoln.
Internally, maybe, but not when dealing with external utilities.
Dealing with the registry is pretty common on Windows.
You don't want to stick with a solution that will orphan
all those windows users do you?
:-)
- Regression -- can't read input w/stderr redirect, L A Walsh, 2017/06/18
- Re: Regression -- can't read input w/stderr redirect, Eduardo A . Bustamante López, 2017/06/18
- Re: Regression -- can't read input w/stderr redirect, Chet Ramey, 2017/06/18
- Re: Regression -- can't read input w/stderr redirect,
L A Walsh <=
- Re: Regression -- can't read input w/stderr redirect, Chet Ramey, 2017/06/18
- Re: Regression -- can't read input w/stderr redirect, L A Walsh, 2017/06/18
- Re: Regression -- can't read input w/stderr redirect, Pierre Gaston, 2017/06/19
- Re: Regression -- can't read input w/stderr redirect, L A Walsh, 2017/06/20
- Re: Regression -- can't read input w/stderr redirect, Greg Wooledge, 2017/06/20
- Re: Regression -- can't read input w/stderr redirect, Chet Ramey, 2017/06/20
- Re: Regression -- can't read input w/stderr redirect, Chet Ramey, 2017/06/19
- Re: Regression -- can't read input w/stderr redirect, Greg Wooledge, 2017/06/19
Re: Regression -- can't read input w/stderr redirect, Robert Elz, 2017/06/19