Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: globcomplete bug + bug when compctl.so not loaded + init patch



Sven Wischnowsky wrote:
> > Looks like things go haywire when globcomplete is set with new completion.
> 
> The problem was that the second pointer into the match wasn't modified 
> together with the main pointer. This caused a wrong value to be placed 
> in one of those cline structs and later this led to an endless loop
> (trying to make a negative and decremented value match a positive value).

This doesn't seem to fix it for me; there's still something wrong in
addmatch() on the same test:

% setopt globcomplete
% setopt glob*e<TAB>

e is still not being set, so ee is wrong, so the second call to str_cline
after `if (ee != ss + sl || (lpsuf && *lspuf))' hangs.

Further up, the code is avoiding the whole file handling branch and
following the

  test = domatch(s, patcomp, 0)

branch of the next main condition around 4344, and is not following the

  if (!test && lpre && lpsuf) {

around 4359, so there's no opportunity for e to be set.

-- 
Peter Stephenson <pws@xxxxxxxxxxxxxxxxx>       Tel: +39 050 844536
WWW:  http://www.ifh.de/~pws/
Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy



Messages sorted by: Reverse Date, Date, Thread, Author