Public bug reported:
Binary package hint: command-not-found
OS: Kubuntu 7.10
Bash Version: 3.2-0ubuntu11
command-not-found version: 0.2.8ubuntu2
-------------------------------------------
I tried to create an own version of command_not_found_handle() containing a
"read" command. This is what happens:
The "read" command sends the process to the background. Strangely, this only
happens if "read" is invoked _behind_ "python /usr/lib/command-not-found", and
the problem does not occur if the function is called explicitly.
$ command_not_found_handle(){ read -p "read 1"; python
/usr/lib/command-not-found -- $1; read -p "read 2"; echo foo; }
$ command_not_found_handle sl
read 1
The program 'sl' is currently not installed. You can install it by typing:
sudo apt-get install sl
read 2
foo
$ # This works as expected. Now let's try to call the function implicitly:
$ sl
read 1
The program 'sl' is currently not installed. You can install it by typing:
sudo apt-get install sl
read 2
[1]+ Stopped sl
$ fg
sl
foo
$
** Affects: command-not-found (Ubuntu)
Importance: Undecided
Status: New
--
unexpected behaviour of read in command_not_found_handle
https://bugs.launchpad.net/bugs/218748
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs