[PATCH] Avoid pronouns in documentation

2021-06-07 Thread Andrew Church
e bad ones, you're asking the wrong question.") I've left pronouns referring to specific individuals unchanged, on the assumption that those pronouns are correct for those individuals. --Andrew Church http://achurch.org/ diff --git a/doc/bashref.texi b/doc/bashref.texi inde

Re: Bash reference manual feedback

2022-09-12 Thread Andrew Church
rs that it's telling >you to avoid. I suspect the intent here was to point out the use of the "smart quote" (U+2019) instead of the intended ASCII single quote (U+0027). --Andrew Church https://achurch.org/

bash-5.0_p1: wildcard expansion bug with unreadable intermediate directories

2019-01-31 Thread Andrew Church
b"/* /tmp/a/b/c /tmp/a/b/c bash-5.0$ chmod -r /tmp/a bash-5.0$ echo /tmp/a/b/* "/tmp/a/"b/* "/tmp/a/b"/* /tmp/a/b/c /tmp/a/b/* Note how the third expansion in the last command fails even though /tmp/a/b is readable. --Andrew Church http://achurch.org/

Re: bash-5.0_p1: wildcard expansion bug with unreadable intermediate directories

2019-01-31 Thread Andrew Church
/* "/tmp/a/b"/* /tmp/a/b/c /tmp/a/b/c /tmp/a/b/* --Andrew Church http://achurch.org/

Re: Segfault after many stackframes

2019-04-12 Thread Andrew Church
e to say 'stack overflow'. That's exactly what bash is saying there. I'm not sure what (if anything) POSIX specifies for stack overflow behavior, but at least on Linux, stack overflow raises SIGSEGV: $ echo 'int main(void) {return main();}' | cc -o foo -x c -

Re: Valgrind detects invalid read in bash. malloc assertion fails.

2019-05-15 Thread Andrew Church
lso avoid this false positive. (Strictly speaking, even the renaming of "free" to "sh_xfree" in xmalloc.h results in undefined behavior by the above rule, but that at least is resolved at compilation time, and I presume there are no real-world build environments in which that renaming causes a problem.) --Andrew Church http://achurch.org/

Re: Use high bits of the raw random number?

2019-05-15 Thread Andrew Church
in the output is from dieharder and is irrelevant -- the generator was seeded with the value 1 in all cases). --Andrew Church http://achurch.org/ $ bashrand-low16

Re: bash sets O_NONBLOCK on pts

2019-10-02 Thread Andrew Church
ted program sets O_NONBLOCK on stdin and then exits, that state will remain until some other program unsets it. For example: $ cat >foo.c #include int main(void) {fcntl(0, F_SETFL, O_NONBLOCK); return 0;} ^D $ cc foo.c $ ./a.out $ cat cat: -: Resource temporarily unavailable --Andrew Church http://achurch.org/

Re: Writing to /dev/stderr overwrites xtrace data

2019-10-30 Thread Andrew Church
trace log lines which were previously written. Bash still has an open file descriptor to stderr, which has its own seek position, so if you add another command (like "exit 1") to the generated script after the echo, the xtrace line generated by that command will be written at that positi

Re: set -e ignored in subshell if part of command list

2019-11-13 Thread Andrew Church
-OR list in rule 2 should be treated differently, and absent an explicit requirement one way or the other, I think the expected behavior here would be that the behavior of the subshell is independent of the subshell's context in the parent shell. --Andrew Church http://achurch.org/

Re: Backspace echoed incorrectly with TERM=garbage

2020-06-18 Thread Andrew Church
dline against ncurses-5.9 (forcing -lncurses), the problem goes away: read(0, "\177", 1) = 1 write(2, "\10 \10", 3) = 3 So the problem may be either in ncurses itself or in readline's interaction with ncurses/libtinfo. --Andrew Church http://achurch.org/