diff options
author | Oliver Kiddle <opk@users.sourceforge.net> | 2003-07-10 10:05:05 +0000 |
---|---|---|
committer | Oliver Kiddle <opk@users.sourceforge.net> | 2003-07-10 10:05:05 +0000 |
commit | 10878a43eb7373ec6774477b15810b7616e5bdc7 (patch) | |
tree | d155528d5205124427ef6f3986ae390e3c1428df /Completion | |
parent | be76af4372019d5d9a16b9aa3324d98cbec57fe0 (diff) | |
download | zsh-10878a43eb7373ec6774477b15810b7616e5bdc7.tar.gz zsh-10878a43eb7373ec6774477b15810b7616e5bdc7.tar.xz zsh-10878a43eb7373ec6774477b15810b7616e5bdc7.zip |
18841: work around problem which caused the whole word to be removed
Diffstat (limited to 'Completion')
-rw-r--r-- | Completion/Base/Completer/_prefix | 6 |
1 files changed, 5 insertions, 1 deletions
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++ )) |