[Bug 1312243] Re: error messages completing args inside $()
Tharrrk
1312243 at bugs.launchpad.net
Fri Jun 5 20:48:31 UTC 2020
Just hit this 6-year old bug.
I haven't upgraded to 20.04 yet but in 18.04 it's still present.
This bug potentially has quite fatal consequences, imagine you type...
for a in $(`reboot`)
...and press <TAB>.
(replace reboot with whatever potentially dangerous command)
eval = EVIL !!!
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to bash-completion in Ubuntu.
https://bugs.launchpad.net/bugs/1312243
Title:
error messages completing args inside $()
Status in bash-completion package in Ubuntu:
Triaged
Status in bash-completion package in Debian:
Fix Released
Bug description:
Hello. Please observe the following transcript (only [TAB] has been
inserted to indicate the position where I hit TAB):
In Trusty:
$ cat <<EOF > foo
> Test
> EOF
$ echo $(< foo)
Test
$ echo $(< fo[TAB]bash: unexpected EOF while looking for matching `)'
bash: syntax error: unexpected end of file
^C
$ echo $(cat fo[TAB]bash: unexpected EOF while looking for matching `)'
bash: syntax error: unexpected end of file
In Saucy:
$ cat <<EOF > foo
> Test
> EOF
$ echo $(< foo)
Test
$ echo $(< fo[TAB]o^C
$ echo $(cat fo[TAB]o^C
Simply put, once I start a command substitution with $( I am not able
to use the [TAB] completion in Trusty any longer while this was
working file in Saucy. I hope this can be fixed soon since it really
hampers use of the command-line. Thanks!
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash-completion/+bug/1312243/+subscriptions
More information about the foundations-bugs
mailing list