diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2011-03-09 21:12:04 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2011-03-09 21:12:04 (GMT) |
commit | 0ff7a2d6e8ac0ddb691cef116027014b60db62f2 (patch) | |
tree | 7bd567d670ce6cc9f3d79b17e1a82616e98036f4 | |
parent | a76a2e1620ef976d57f36b369e597150317606f9 (diff) | |
download | hdf5-0ff7a2d6e8ac0ddb691cef116027014b60db62f2.zip hdf5-0ff7a2d6e8ac0ddb691cef116027014b60db62f2.tar.gz hdf5-0ff7a2d6e8ac0ddb691cef116027014b60db62f2.tar.bz2 |
[svn-r20218] Valgrind fix for memory leak in print_datatype which used an allocation function in a printf().
Tested: local linux and valgrind
-rw-r--r-- | tools/h5dump/h5dump.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/h5dump/h5dump.c b/tools/h5dump/h5dump.c index 5f4842a..571a05a 100644 --- a/tools/h5dump/h5dump.c +++ b/tools/h5dump/h5dump.c @@ -1164,7 +1164,9 @@ print_datatype(hid_t type,unsigned in_group) indentation(indent + COL); printf("H5T_OPAQUE;\n"); indentation(indent + COL); - printf("OPAQUE_TAG \"%s\";\n", H5Tget_tag(type)); + mname = H5Tget_tag(type); + printf("OPAQUE_TAG \"%s\";\n", mname); + free(mname); indentation(indent); break; |