diff options
author | Raymond Lu <songyulu@hdfgroup.org> | 2002-11-19 14:50:04 (GMT) |
---|---|---|
committer | Raymond Lu <songyulu@hdfgroup.org> | 2002-11-19 14:50:04 (GMT) |
commit | 5f91db8d68d20d8106a58467c73fce15a953807a (patch) | |
tree | cddd7ae4dafcaa1fd26e9cd24322d07e514063d1 /tools/h5dump/h5dump.c | |
parent | 0105a3b97cabccd3463c82c22da7e3f4d23c2b05 (diff) | |
download | hdf5-5f91db8d68d20d8106a58467c73fce15a953807a.zip hdf5-5f91db8d68d20d8106a58467c73fce15a953807a.tar.gz hdf5-5f91db8d68d20d8106a58467c73fce15a953807a.tar.bz2 |
[svn-r6102]
Purpose:
bug fix
Description:
forgot to change datatype print-out when fixed VL string bug for h5dump.
Platforms tested:
modi4
Diffstat (limited to 'tools/h5dump/h5dump.c')
-rw-r--r-- | tools/h5dump/h5dump.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/tools/h5dump/h5dump.c b/tools/h5dump/h5dump.c index 36250d3..c1abc13 100644 --- a/tools/h5dump/h5dump.c +++ b/tools/h5dump/h5dump.c @@ -3499,7 +3499,8 @@ xml_print_datatype(hid_t type) size_t mpos; size_t msize; int nmembs; - + htri_t is_vlstr=FALSE; + switch (H5Tget_class(type)) { case H5T_INTEGER: indentation(indent); @@ -3593,7 +3594,8 @@ xml_print_datatype(hid_t type) size = H5Tget_size(type); str_pad = H5Tget_strpad(type); cset = H5Tget_cset(type); - + is_vlstr = H5Tis_variable_str(type); + indentation(indent); printf("<AtomicType>\n"); indent += COL; @@ -3604,7 +3606,10 @@ xml_print_datatype(hid_t type) } else { printf("unknown_cset\" "); } - printf("StrSize=\"%d\" StrPad=\"", (int) size); + if(is_vlstr) + printf("StrSize=\"H5T_VARIABLE\" StrPad=\""); + else + printf("StrSize=\"%d\" StrPad=\"", (int) size); if (str_pad == H5T_STR_NULLTERM) { printf("H5T_STR_NULLTERM\"/>\n"); } else if (str_pad == H5T_STR_NULLPAD) { |