[Nexus-developers] Yet another memory leak!

Mark Koennecke Mark.Koennecke at psi.ch
Tue Mar 20 12:46:36 GMT 2007


Hi Stephane,

POIRIER Stephane schrieb:
> Hi,
>
> [Before sending this e-mail I've tried to report the issue using the dedicated web page (http://trac.nexusformat.org/code/) but the login dialog has rejected my NeXus wiki user name & password.]
>
> So this memory leak comes with the NXgetgroupID function. Calling it in the inner loop of the leak_test2.cxx (near line 37) and allow debug output in napi5.cpp show that for each call to NXgetgroupID a HDF5 datatype object is never freed:
>
> file 0
> HDF5 object count before close: 1
> HDF5 object count after close: 100
> HDF5 dataset count after close: 0
> HDF5 group count after close: 0
> HDF5 datatype count after close: 100
> HDF5 attribute count after close: 0
> file 1
> HDF5 object count before close: 1
> HDF5 object count after close: 200
> HDF5 dataset count after close: 0
> HDF5 group count after close: 0
> HDF5 datatype count after close: 200
> HDF5 attribute count after close: 0
> file 2
> HDF5 object count before close: 1
> HDF5 object count after close: 300
> HDF5 dataset count after close: 0
> HDF5 group count after close: 0
> HDF5 datatype count after close: 300
> HDF5 attribute count after close: 0
> file3
> ...
>
> The technical environment is unchanged:
> - NeXus API 3.0.0 (with memory leaks fixed for time_buffer allocation and H5Pcreate() calling in NX5Open function)
> - OS Linux RHEL4
> - gcc 3.4.4
>
> Thanks for your attention.
>   
I failed to verify this bug against  NAPI-4.0. As I did some major 
cleanup of napi5.c for NAPI-4 it is quite possible that I squashed
the bug along the way. Is it OK for you to wait for NAPI-4.0 or do I 
have to get NAPI-3.0 fixed?


                   Best Regards,

                              Mark Koennecke



More information about the NeXus-developers mailing list