Clean [1.2.3.4]:port format in known_hosts, thanks to Xuefer (Gentoo: #284563)

master
David Paleino 2009-09-17 23:05:52 +02:00
parent 3a69bd3e93
commit f061b21ef9
2 changed files with 4 additions and 0 deletions

View File

@ -36,6 +36,8 @@ bash-completion (1.x)
* Improve qemu completion (Debian: #534901)
* Added sshfs completion (shares the same as scp) (Debian: #545978)
* Fixed obvious brokenness (typos) in contrib/mdadm
* Clean [1.2.3.4]:port format in known_hosts, thanks to
Xuefer (Gentoo: #284563)
* Patches from PLD Linux (thanks to Elan Ruusamäe):
- avoid sed pipe as ps itself can omit the headers
- improve service(8) completion, also look for "msg_usage"

View File

@ -1172,6 +1172,8 @@ _known_hosts_real()
COMPREPLY=( $( awk 'BEGIN {FS=","}
/^\s*[^|\#]/ {for (i=1; i<=2; ++i) { \
gsub(" .*$", "", $i); \
gsub("[\\[\\]]", "", $i); \
gsub(":[0-9]+$", "", $i); \
if ($i ~ /'"$awkcur"'/) {print $i} \
}}' "${kh[@]}" 2>/dev/null ) )
fi