summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVille Skyttä <ville.skytta@iki.fi>2010-01-26 23:17:48 +0200
committerVille Skyttä <ville.skytta@iki.fi>2010-01-26 23:17:48 +0200
commit6328b108a2b48e93b7e5f58016124a6b5c878a57 (patch)
tree33813ac5dc1706b1c517447ae0d06ecdaa77c2a8
parentdc8af65161fecc37d2d2ab15c02d8f529d27c3b5 (diff)
downloadbash-completion-6328b108a2b48e93b7e5f58016124a6b5c878a57.tar.gz
Fix NFS completion if path to showmount contains spaces (Alioth: #312285).
-rw-r--r--contrib/mount4
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/mount b/contrib/mount
index f9fafb17..d8ba81bc 100644
--- a/contrib/mount
+++ b/contrib/mount
@@ -18,8 +18,8 @@ _mount()
if [[ "$cur" == *:* ]]; then
for sm in $(type -P showmount) {,/usr}/{,s}bin/showmount; do
- [ -x $sm ] || continue
- COMPREPLY=( $( compgen -W "$( $sm -e ${cur%%:*} | \
+ [ -x "$sm" ] || continue
+ COMPREPLY=( $( compgen -W "$( "$sm" -e ${cur%%:*} | \
awk 'NR>1 {print $1}' )" -- "${cur#*:}" ) )
return 0
done