diff options
author | Tanaka Akira <akr@users.sourceforge.net> | 1999-10-15 14:14:30 +0000 |
---|---|---|
committer | Tanaka Akira <akr@users.sourceforge.net> | 1999-10-15 14:14:30 +0000 |
commit | 974d332d8989e85ad2edf95e5e467c6d8b111b38 (patch) | |
tree | 3d9a818d587df460cc30e0e0668a8501805c5186 /Src | |
parent | d9ffb668fa53c3e74fa1bd86e04817b67f04b8e9 (diff) | |
download | zsh-974d332d8989e85ad2edf95e5e467c6d8b111b38.tar.gz zsh-974d332d8989e85ad2edf95e5e467c6d8b111b38.tar.xz zsh-974d332d8989e85ad2edf95e5e467c6d8b111b38.zip |
zsh-workers/8283
Diffstat (limited to 'Src')
-rw-r--r-- | Src/Zle/zle_tricky.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Src/Zle/zle_tricky.c b/Src/Zle/zle_tricky.c index 684e8e926..70371b41c 100644 --- a/Src/Zle/zle_tricky.c +++ b/Src/Zle/zle_tricky.c @@ -157,7 +157,7 @@ int newmatches; /* Number of permanently allocated matches and groups. */ -static int permmnum, permgnum; +static int permmnum, permgnum, lastpermmnum, lastpermgnum; /* The total number of matches and the number of matches to be listed. */ @@ -5123,7 +5123,7 @@ callcompfunc(char *s, char *fn) comptoend = ztrdup("match"); zsfree(compoldlist); zsfree(compoldins); - if (hasoldlist && permmnum) { + if (hasoldlist && lastpermmnum) { if (listshown) compoldlist = "shown"; else @@ -5359,6 +5359,8 @@ makecomplist(char *s, int incmd, int lst) } permmatches(1); amatches = pmatches; + lastpermmnum = permmnum; + lastpermgnum = permgnum; } LASTALLOC; lastmatches = pmatches; @@ -8592,7 +8594,7 @@ do_ambig_menu(void) minfo.cur = NULL; } if (insgroup) { - insgnum = comp_mod(insgnum, permgnum); + insgnum = comp_mod(insgnum, lastpermgnum); for (minfo.group = amatches; minfo.group && (minfo.group)->num != insgnum + 1; minfo.group = (minfo.group)->next); @@ -8603,7 +8605,7 @@ do_ambig_menu(void) } insmnum = comp_mod(insmnum, (minfo.group)->mcount); } else { - insmnum = comp_mod(insmnum, permmnum); + insmnum = comp_mod(insmnum, lastpermmnum); for (minfo.group = amatches; minfo.group && (minfo.group)->mcount <= insmnum; minfo.group = (minfo.group)->next) |