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

Re: big key binding patch

>This key binding overhaul was certainly necessary.

It certainly was, Stanley.

>the str Key element doesn't get set to null in addkeybindentry(),
>causing `already free' error messages later.  However, is the
>zfree(cur->str) immediately after the addkeybindentry() in
>bin_bindkey() still required?  It's not quite clear to me since the
>test at the end of addkeybindentry() is different (and so is the free,
>but that must be essentially cosmetic).

Urgh.  I'm planning another patch, after the next release, which among
other things will clean up this area of bin_bindkey() quite a bit.

>There's also some not-bugs with uninitialized variables that gcc complains
>about which I've fixed anyway (that's the current policy, not clear
>how necessary it really is but it eliminates a source of complaints).

Yes, I wonder why those didn't show up when I first compiled the new code.

>I still had -pedantic turned on when I first compiled this and gcc
>doesn't like having to initialise the keybindtab elements of list[] in
>unbindzlefunc() at load time.  That probably needs fixing (if there
>are any genuinely pedantic compilers around) but I couldn't think of a
>portable fix without more verbose code.

That'll teach me to assume that someone else was mistaken.  The code I
replaced had HashTable *'s in that list, and extra dereferences.


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