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

Re: Weird completion bug in Src/Zle/compmatch.c#bld_line



Woops... I feel like an Apple engineer in front of the "goto fail;" bug...

Be back with more tea soon!

Nicolas Canceill


Le 9 juin 2014 à 15:25, Jun T. <takimoto-j@xxxxxxxxxxxxxxxxx> a écrit :

> What you are getting is not a mystery at all, but may give some hint.
> 
> In your patch:
> 
> 	    if (!ms)
> +                closelog();
> 		return 0;	/* Didn't match, give up */
> 
> but you need a block { .. } here, as follows:
> 
> 	    if (!ms) {
>                closelog();
> 		return 0;	/* Didn't match, give up */
> 	    }
> 
> 
> If you use your patch, the function returns 0 even if ms is not NULL.
> In the original code, the function returns 0 if ms is NULL and llen is 0;
> otherwise it returns rl.
> 
> I guess your journey continues...



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