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

fix for completing to NULs



-----BEGIN PGP SIGNED MESSAGE-----

If completing to a string ending in NUL, the completion code thinks
that the space of the metafied NUL is a suffix, and so puts the
cursor in the wrong place.  This fixes it.

 -zefram

      Index: Src/zle_tricky.c
      *** zle_tricky.c	1996/05/23 12:31:34	1.18
      --- zle_tricky.c	1996/05/23 13:16:17
      ***************
      *** 3343,3349 ****
        	if (menuend > ll)
        	    menuend = ll;
        	if (menuend && ((((char)line[menuend - 1]) != singlec) ||
      ! 		(menuend > 1 && singlec == ' ' && line[menuend - 2] == '\\')))
        	    if (parampre && singlec == '/' && ((char)line[menuend]) == '/')
        		addedsuffix = 0;
        	    /* Now insert the slash or space if there is none already. */
      --- 3343,3350 ----
        	if (menuend > ll)
        	    menuend = ll;
        	if (menuend && ((((char)line[menuend - 1]) != singlec) ||
      ! 	    (menuend > 1 && singlec == ' ' &&
      ! 	      (line[menuend - 2] == '\\' || line[menuend - 2] == STOUC(Meta)))))
        	    if (parampre && singlec == '/' && ((char)line[menuend]) == '/')
        		addedsuffix = 0;
        	    /* Now insert the slash or space if there is none already. */

-----BEGIN PGP SIGNATURE-----
Version: 2.6.2

iQCVAwUBMaRnXXD/+HJTpU/hAQGEnwP/W2rlbWq36yZebaJNWZkEpRvLI45okJOO
FIDu0b2B0rlmqe+1cAr73sk0ZyVQq9YHDEhmkJuItffc0J0MD33rLshTyuUGy1TE
kEQYosHY8/X4M+Ya95Tc+2x9735fXVEjuSG5t1MHVzE6UzkfQAGKCzPnhuMjPXb4
dIuymbc/XPw=
=9+VI
-----END PGP SIGNATURE-----




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