Re: Bug in bash read builtin, info from while read REPLY leaking into separate red -r -p "$1" command in function

2025-02-08 Thread Robert Elz
Date:Sat, 8 Feb 2025 19:33:10 -0500 From:Greg Wooledge Message-ID: <20250209003310.gm29...@wooledge.org> | You really want bash's ${var//search/replace} feature for the | renaming step, In some cases I might agree, not necessarily about the mechanism, but about d

Re: DKIM Signature Issue Causing Mailing List Posts to be Marked as Spam

2025-02-08 Thread Lawrence Velázquez
On Sat, Feb 8, 2025, at 8:57 PM, Ángel wrote: > I expect you to take this issue seriously and take the needed measures > to ensure their wrong ways are fixed. Alas, OP announced off-list that they have unsubscribed. If you were to send your guidance to them directly, I'm sure they would show you

Re: DKIM Signature Issue Causing Mailing List Posts to be Marked as Spam

2025-02-08 Thread Ángel
On 2025-02-03 at 19:00 -0500, Zeffie wrote: > I wanted to bring to your attention that the bash-bug mailing list > messages are being marked as spam by our spam filtering. The debug > headers indicate an "Invalid DKIM signature" which appears to be > causing the posts to be flagged. As you hav

Re: Bug in bash read builtin, info from while read REPLY leaking into separate red -r -p "$1" command in function

2025-02-08 Thread Greg Wooledge
On Sun, Feb 09, 2025 at 06:35:38 +0700, Robert Elz wrote: > ps: there is almost never a good excuse to use non-standard sh > extensions (bash's, or any other shells), when writing a standard > conforming script would allow any Bourne shell variant to > work, and that's certainly the case here, and

Re: Bug in bash read builtin, info from while read REPLY leaking into separate red -r -p "$1" command in function

2025-02-08 Thread Robert Elz
Date:Sat, 8 Feb 2025 12:08:10 -0500 From:Greg Wooledge Message-ID: <20250208170810.gl29...@wooledge.org> | OK, I think you have something like this: | | while read -r f; do | if [[ $f = *[[:space:]]* ]]; then | read -r -p "Fix <$f>? " yn |

Re: Bug in bash read builtin, info from while read REPLY leaking into separate red -r -p "$1" command in function

2025-02-08 Thread Chet Ramey
On 2/8/25 10:48 AM, carlyle_moul...@optusnet.com.au wrote: Then follows a while read REPLY; do # loop to read records from /tmp/$USER/tempfile1 # The first record is discarded, from the remainder the File_Name is extracted and passed to a functionas a quoted string to function File_Contains_Blan

Re: Bug in bash read builtin, info from while read REPLY leaking into separate red -r -p "$1" command in function

2025-02-08 Thread Greg Wooledge
On Sun, Feb 09, 2025 at 02:48:42 +1100, carlyle_moul...@optusnet.com.au wrote: > I have a script to go through file names in the current directory, > check whether they contain blanks and optionally replace blanks with > underscores. for f in *[[:space:]]*; do read -r -p "Fix <$f>? " yn if

Bug in bash read builtin, info from while read REPLY leaking into separate red -r -p "$1" command in function

2025-02-08 Thread carlyle_moulton
From: carl To: bug-bash@gnu.org Subject: [50 character or so descriptive subject here (for reference)] In a script two instances of the read builtin mutually interfere Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc Compilation CFLAGS:

Re: "printf %d ''" should diagnose the empty string

2025-02-08 Thread Phi Debian
On Sat, Feb 8, 2025 at 10:31 AM Robert Elz wrote: > > > It isn't a valid form for a C constant.bash allows that kind of thing > in its arithmetic contexts, but this is not one. > > Jeez moving target, thanks to bring C in the loop I got it now :-) I like this orthogonality :-) $ printf '%d\n

Re: "printf %d ''" should diagnose the empty string

2025-02-08 Thread Robert Elz
Date:Sat, 8 Feb 2025 10:09:30 +0100 From:Phi Debian Message-ID: | Why 2#1 is invalid ? It isn't a valid form for a C constant.bash allows that kind of thing in its arithmetic contexts, but this is not one. You did notice that printf printed '2' not the bash

Re: "printf %d ''" should diagnose the empty string

2025-02-08 Thread Phi Debian
Hi, My personal vote is for no printf warning on bad format of %fmt args, but other may argue against that. This is no big deal because I can always do in my scripts alias printf='printf 2>/dev/null' That being said if warnings are printed I suppose they must be accurate ? I don't really get thi