[Hdf-forum] Errors from valgrind for tutorial examples

digitalriptide digitalriptide at gmail.com
Mon Aug 4 16:51:40 CDT 2014


I built the C language example from
http://www.hdfgroup.org/HDF5/Tutor/crtfile.html, but obtained the following
errors in valgrind:

valgrind --leak-check=full --show-reachable=yes ./a.out
==30926== Memcheck, a memory error detector
==30926== Copyright (C) 2002-2011, and GNU GPL'd, by Julian Seward et al.
==30926== Using Valgrind-3.7.0 and LibVEX; rerun with -h for copyright info
==30926== Command: ./a.out
==30926==
==30926==
==30926== HEAP SUMMARY:
==30926==     in use at exit: 1,336 bytes in 3 blocks
==30926==   total heap usage: 1,994 allocs, 1,991 frees, 728,019 bytes
allocated
==30926==
==30926== 8 bytes in 1 blocks are still reachable in loss record 1 of 3
==30926==    at 0x4C29DB4: calloc (in
/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==30926==    by 0x5143883: H5TS_cancel_count_inc (in
/usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4E5D12F: H5check_version (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4006AF: main (in /home/rdl/tm/a.out)
==30926==
==30926== 16 bytes in 1 blocks are still reachable in loss record 2 of 3
==30926==    at 0x4C2B6CD: malloc (in
/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==30926==    by 0x4F1A1FF: ??? (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4F1A4FE: H5FL_reg_malloc (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4EE6038: H5E_get_stack (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4EED0B3: H5E_clear_stack (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4EF1DCF: H5Fcreate (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4006C8: main (in /home/rdl/tm/a.out)
==30926==
==30926== 1,312 bytes in 1 blocks are still reachable in loss record 3 of 3
==30926==    at 0x4C2B6CD: malloc (in
/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==30926==    by 0x4F1A0E0: ??? (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4F1A5DF: H5FL_reg_malloc (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4EE6038: H5E_get_stack (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4EED0B3: H5E_clear_stack (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4EF1DCF: H5Fcreate (in /usr/lib/libhdf5.so.6.0.3)
==30926==    by 0x4006C8: main (in /home/rdl/tm/a.out)
==30926==
==30926== LEAK SUMMARY:
==30926==    definitely lost: 0 bytes in 0 blocks
==30926==    indirectly lost: 0 bytes in 0 blocks
==30926==      possibly lost: 0 bytes in 0 blocks
==30926==    still reachable: 1,336 bytes in 3 blocks
==30926==         suppressed: 0 bytes in 0 blocks
==30926==
==30926== For counts of detected and suppressed errors, rerun with: -v
==30926== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 2 from 2)

Am I doing something incorrect, or are these errors expect from the
library? They appear innocuous, but it would be nice to eliminate them, if
possible. I am testing with HDF5 1.8.4 and gcc 4.6.3.

Thank you for any assistance.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.lists.hdfgroup.org/pipermail/hdf-forum_lists.hdfgroup.org/attachments/20140804/c80d9e3a/attachment.html>


More information about the Hdf-forum mailing list