* zsh-3.1.5-pws4. accept-and-menu-complete bug?
@ 1998-12-31 7:58 Andrej Borsenkow
1999-01-04 2:14 ` Bart Schaefer
0 siblings, 1 reply; 2+ messages in thread
From: Andrej Borsenkow @ 1998-12-31 7:58 UTC (permalink / raw)
To: ZSH workers mailing list
Something strange here
bor@itsrm2:/tools/src%> bindkey '^[^M'
"^[^M" accept-and-menu-complete
bor@itsrm2:/tools/src%> rm -rf mc-4.5.1/
mc-4.5.1/ mc-4.5.3/
(now press ESC-RETURN):
bor@itsrm2:/tools/src%> rm -rf mc-4.5.1/^@mc-4.5.3/
mc-4.5.1/ mc-4.5.3/
Note this ^@ and not removed suffix instead of blank.
bor@itsrm2:/tools/src%> echo $ZSH_VERSION
3.1.5-pws-4
The same with zsh -f and single bindkey for ESC-RET
Happy New Year to everybody!
/andrej
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: zsh-3.1.5-pws4. accept-and-menu-complete bug?
1998-12-31 7:58 zsh-3.1.5-pws4. accept-and-menu-complete bug? Andrej Borsenkow
@ 1999-01-04 2:14 ` Bart Schaefer
0 siblings, 0 replies; 2+ messages in thread
From: Bart Schaefer @ 1999-01-04 2:14 UTC (permalink / raw)
To: Andrej Borsenkow, ZSH workers mailing list
On Dec 31, 10:58am, Andrej Borsenkow wrote:
} Subject: zsh-3.1.5-pws4. accept-and-menu-complete bug?
}
} bor@itsrm2:/tools/src%> bindkey '^[^M'
} "^[^M" accept-and-menu-complete
} bor@itsrm2:/tools/src%> rm -rf mc-4.5.1/^@mc-4.5.3/
} mc-4.5.1/ mc-4.5.3/
}
} Note this ^@ and not removed suffix instead of blank.
In acceptandmenucomplete() in zle_tricky.c, there's this fragment:
cs = menuend + menuinsc;
inststrlen(" ", 1, 1);
menuinsc = menulen = 0;
menupos = cs;
menuend is supposed to be "the end position of this string in the command
line" and menuinsc "is the length of any suffix that has been temporarily
added." However, at that point menuend is large enough to *include* the
trailing slash. In 3.0.5's acceptandmenucomplete(), menuinsc is not added
when computing cs.
So I don't know if this is a general problem -- that menuend is just plain
wrong, and anything that refers to it will be messed up -- or if that ref
to menuinsc crept in by mistake and should be deleted (in which case the
suffix doesn't get autoremoved), or if there's a whole lot of suffix-removal
code that ought to be copied from 3.0.5, or what.
Sven?
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1999-01-04 2:21 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-12-31 7:58 zsh-3.1.5-pws4. accept-and-menu-complete bug? Andrej Borsenkow
1999-01-04 2:14 ` Bart Schaefer
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).