Memory leaks in standard code
FX Coudert
fxcoudert@gmail.com
Wed Feb 27 11:09:00 GMT 2008
> This new version of your patch segfaults at line 165 of memory_check.c
> with x86_ia64/FC8. Should this line not be:
>
> if (*slot != HTAB_DELETED_ENTRY)
> free (*slot);
On what code does it segfault? I think *slot == HTAB_DELETED_ENTRY is
a weird error condition, like freeing twice the same pointer. Or yet
another problem in my hashtabs :(
> The test that I performed is with the patched version of the
> alloc_comp code, as I remarked in the first email in this thread.
> With the above modification to memory checking, it gives no memory
> leaks, which is what the 'original' code is telling me.
Here, with the patched alloc_comp_code (sorry for forgetting that),
it reports no memleak (and no segfault either).
> Several other members of the allocatable component members of the
> testsuite show memory leaks, however. Many thanks for a brilliant
> tool!
Well, we'll have to see if they are really memory leaks or just
issues with my patch. Many thanks for helping me debug it, by the way!
FX
--
François-Xavier Coudert
http://www.homepages.ucl.ac.uk/~uccafco/
More information about the Fortran
mailing list