Here's another memory leak fix along with a small doc fix. There seems to be some situations when the following code will see uninitialized memory reads from the following stack: pattern_match [compmatch.c:1035] match_str [compmatch.c:577] comp_match [compmatch.c:941] addmatches [compcore.c:1954] bin_compadd [complete.c:595] I haven't looked into this, so if more details are needed let me know. --- Sven Wischnowsky wrote: >Hmm. Maybe we get this because some parameter setfn() neither uses nor >frees the string it gets. I took a look at some of the memory that wasn't freed, and found one of the strings had a value that only came out of the value of complist ("ambiguous packed rows"). So something that touches that value has a problem. Maybe a parameter operator. >I can't see where this comes from. mkautofn() creates the >autofn-program wich is then freed in loadautofn() (or >freeshfuncnode(), with ksh-autoloading). > >All these autofn-progs won't be freed at the end, though (together >with many other things). I can see these errors even before the shell exits. The memory checker will only list a memory leak if there are no pointers in memory to a memory block. We are probably losing the pointer to the memory from buitlin.c:2162. -FR __________________________________________________ Do You Yahoo!? Yahoo! Photos -- now, 100 FREE prints! http://photos.yahoo.com