Hi,

I am trying to port HDF5 to delphi.
The main hindrance are functions that return char * in hdf5dll.dll
After all it is impossible to free that string without access violation, for
example:
member_name := H5Tget_member_name(mem_type_id, i);
FreeMemory(member_name ); //Access violation here

I have avoided that situation compiling hdf5dll with additional function:

adding in 
h5public.h

H5_DLL herr_t H5FreeMem(char * memToFree);

adding in
H5.c

herr_t 
H5FreeMem(char * memToFree)
{
 FUNC_ENTER_API_NOINIT_NOERR_NOFS
 H5TRACE0("e","");
free(memToFree);
FUNC_LEAVE_API_NOFS(SUCCEED)
} /* end H5FreeMem() */

If there is no similar functionality (may be I dont know where it is
hiding), it woud be nice to have this enhancement in future version of HDF5.

Regards, 
Saulius



--
View this message in context: 
http://hdf-forum.184993.n3.nabble.com/Porting-HDF5-to-Delphi-tp4025566.html
Sent from the hdf-forum mailing list archive at Nabble.com.

_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org

Reply via email to