$COMP_POINT: substring expression < 0 when tabbing after Ctrl-R sudo
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bash-completion (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: bash-completion
After confirming a command found by Ctrl-R with Tab, if it starts with sudo, the command supplied is wrong, and there are error messages on the console.
How to reproduce:
1. Run "sudo echo test command" for it to be in the history.
2. Press Ctrl-R, type "sudo ec", press Tab.
3. Press Enter.
Expected results:
$ sudo echo test command
test command
$
Actual results:
After (2):
$ bash: $COMP_POINT: substring expression < 0
bash: $COMP_POINT: substring expression < 0
bash: COMP_WORDS: bad array subscript
--
After (3):
--sudo: command not found
$
ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: bash-completion 1:1.1-3ubuntu2
ProcVersionSign
Uname: Linux 2.6.32-21-generic x86_64
NonfreeKernelMo
Architecture: amd64
Date: Tue Apr 20 13:07:11 2010
PackageArchitec
ProcEnviron:
LANGUAGE=
PATH=(custom, user)
LANG=ru_RU.UTF-8
SHELL=/bin/bash
SourcePackage: bash-completion
I also get:
$ bash: $COMP_POINT: substring expression < 0
bash: $COMP_POINT: substring expression < 0
bash: COMP_WORDS: bad array subscript