From 10878a43eb7373ec6774477b15810b7616e5bdc7 Mon Sep 17 00:00:00 2001 From: Oliver Kiddle Date: Thu, 10 Jul 2003 10:05:05 +0000 Subject: 18841: work around problem which caused the whole word to be removed --- Completion/Base/Completer/_prefix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Completion') diff --git a/Completion/Base/Completer/_prefix b/Completion/Base/Completer/_prefix index 3ec153245..a198f4cfb 100644 --- a/Completion/Base/Completer/_prefix +++ b/Completion/Base/Completer/_prefix @@ -48,7 +48,11 @@ for tmp in "$comp[@]"; do [[ compstate[nmatches] -gt 1 ]] && return 0 compadd -U -i "$IPREFIX" -I "$ISUFFIX" - "${compstate[unambiguous]%$suf}x" compstate[list]= - compstate[insert]=unambiguous + if [[ -n $compstate[unambiguous] ]]; then + compstate[insert]=unambiguous + else + compstate[insert]=0 + fi return 0 fi (( _matcher_num++ )) -- cgit 1.4.1