summaryrefslogtreecommitdiff
path: root/Completion/Unix/Command/_sccs
diff options
context:
space:
mode:
authorOliver Kiddle <opk@users.sourceforge.net>2003-06-25 09:03:04 +0000
committerOliver Kiddle <opk@users.sourceforge.net>2003-06-25 09:03:04 +0000
commita267832ddf4150652fde3936858841bb2edbd9ae (patch)
tree961f0cbcaf8dbdaf2ff2e1a5409d644158f592bf /Completion/Unix/Command/_sccs
parentdd54fb249881fa882319cd2642780dcebb8d9f7c (diff)
downloadzsh-a267832ddf4150652fde3936858841bb2edbd9ae.tar.gz
zsh-a267832ddf4150652fde3936858841bb2edbd9ae.zip
18631: returning too early breaks prefix-needed style set to false
Diffstat (limited to 'Completion/Unix/Command/_sccs')
-rw-r--r--Completion/Unix/Command/_sccs9
1 files changed, 5 insertions, 4 deletions
diff --git a/Completion/Unix/Command/_sccs b/Completion/Unix/Command/_sccs
index b3b6f49e9..40463b2f1 100644
--- a/Completion/Unix/Command/_sccs
+++ b/Completion/Unix/Command/_sccs
@@ -15,7 +15,7 @@ _sccs_files() {
return ret
}
-local curcontext="$curcontext" state line
+local curcontext="$curcontext" state line ret=1
typeset -A opt_args
local subcmds ropt copt sfiles finalpath
@@ -56,12 +56,13 @@ if [[ $service = sccs ]]; then
'-r[run with real and not effective user ID]' \
'-d+[specify root prefix]:root prefix:_directories' \
'-p+[specify subdirectory of history file]:path to history file:_directories' \
- '*::command:->subcmd' && return 0
+ '*::command:->subcmd' && ret=0
if (( CURRENT == 1 )); then
- _describe -t commands 'sccs command' subcmds
- return
+ _describe -t commands 'sccs command' subcmds && ret=0
fi
+ (( ret )) || return 0
+
service="$words[1]"
sfiles=':file:_sccs_files'
curcontext="${curcontext%:*}-$service:"