Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Memory leaks.
- X-seq: zsh-workers 11719
- From: Felix Rosencrantz <f_rosencrantz@xxxxxxxxx>
- To: zsh-workers <zsh-workers@xxxxxxxxxxxxxx>
- Subject: Memory leaks.
- Date: Thu, 1 Jun 2000 23:06:40 -0700 (PDT)
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Since, we are sort of in a holding pattern to get a stable release,
I started doing some automated memory leak testing.
I've already posted a couple patches, here are some possible remaining leaks
that need to be fixed.
Most of these were found by running the tests. Some are from just my
usage of zsh.
The possible sources of the memory leaks are:
bin_compadd()
addvars()
mkautofn()
permmatches()
-FR
Memory leak from bin_compadd():
malloc [rtlib.o]
zcalloc [mem.c:469]
parse_cmatcher [complete.c:294]
bin_compadd [complete.c:580]
execbuiltin [builtin.c:368]
execcmd [exec.c:2257]
Another leak in bin_compadd:
malloc [rtlib.o]
zalloc [mem.c:453]
ztrdup [mem.c:530]
bin_compadd [complete.c:574]
execbuiltin [builtin.c:368]
execcmd [exec.c:2257]
I think this is due to the fact that we do a tricat on complete.c:572, without
freeing the previous values of mstr.
Memory leak from addvars():
malloc [rtlib.o]
zalloc [mem.c:453]
ztrdup [mem.c:530]
addvars [exec.c:1510]
execsimple [exec.c:750]
execlist [exec.c:801]
Memory leak out of mkautofn():
malloc [rtlib.o]
zalloc [mem.c:453]
mkautofn [builtin.c:2161]
bin_functions [builtin.c:2143]
execbuiltin [builtin.c:368]
execcmd [exec.c:2257]
Alternate stack traces with the same malloc/zalloc/mkautofn stack:
mkautofn
bin_functions [builtin.c:2143]
bin_typeset [builtin.c:1810]
execbuiltin [builtin.c:368]
mkautofn
eval_autoload [builtin.c:2021]
bin_functions [builtin.c:2078]
execbuiltin [builtin.c:368]
mkautofn
bin_functions [builtin.c:2143]
execbuiltin [builtin.c:368]
execcmd [exec.c:2257]
Memory leak from memory allocated in permmatches():
malloc [rtlib.o]
zcalloc [mem.c:469]
permmatches [compcore.c:2771]
get_nmatches [complete.c:1057]
getstrvalue [params.c:1367]
getarg [params.c:967]
Another trace:
permmatches [compcore.c:2771]
list_lines [compresult.c:1154]
get_listlines [complete.c:1064]
getstrvalue [params.c:1367]
Memory leak from set_gmatcher():
malloc [rtlib.o]
zcalloc [mem.c:469]
parse_cmatcher [complete.c:294]
set_gmatcher [compctl.c:313]
get_gmatcher [compctl.c:341]
bin_compctl [compctl.c:1587]
(I guess this is still in my startup files...)
__________________________________________________
Do You Yahoo!?
Yahoo! Photos -- now, 100 FREE prints!
http://photos.yahoo.com
Messages sorted by:
Reverse Date,
Date,
Thread,
Author