[Bash-completion-devel] [bash-completion-Bugs][312163] Replace uses of echo with printf or redirection
bash-completion-bugs at alioth.debian.org
bash-completion-bugs at alioth.debian.org
Sat Nov 26 22:31:14 UTC 2011
Bugs item #312163, was changed at 2009-12-15 23:57 by Ville Skyttä
You can respond by visiting:
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=312163&group_id=100114
>Status: Closed
Priority: 3
Submitted By: Ville Skyttä (scop-guest)
>Assigned to: Ville Skyttä (scop-guest)
Summary: Replace uses of echo with printf or redirection
Distribution: None
Originally reported in: None
Milestone: None
>Status: Fix Committed
Original bug number: 312143
Initial Comment:
Copied from #312143:
We'd better never use echo, but `printf' (or redirection) instead
because if an argument to echo happens to be -e or -n, it is
interpreted wrongly as an option:
$ a=-n
$ echo "$a" # Error: Nothing is output
$ printf "%s" "$a" # Ok: -n gets output
-n$
----------------------------------------------------------------------
>Comment By: Ville Skyttä (scop-guest)
Date: 2011-11-27 00:31
Message:
There's only one echo in the whole tree that I suppose could theoretically be subject to this problem as of git rev 6a713c3, so I think we can call this done.
If someone's interested, the only remaining one is in _muttaliases() -- I couldn't figure out how to convert it to printf in 2 minutes without breaking the related test case.
----------------------------------------------------------------------
You can respond by visiting:
https://alioth.debian.org/tracker/?func=detail&atid=413095&aid=312163&group_id=100114
More information about the Bash-completion-devel
mailing list