diff options
author | Raymond Lu <songyulu@hdfgroup.org> | 2009-12-09 16:15:45 (GMT) |
---|---|---|
committer | Raymond Lu <songyulu@hdfgroup.org> | 2009-12-09 16:15:45 (GMT) |
commit | 7d8ceade335c6528ba4cdbb386c36e918e02ee44 (patch) | |
tree | d16efe58476385a5e9529281a67c6211762f651a /src/H5Dint.c | |
parent | 4f90de0956d5f6406f4bed659dc50ffd971c014c (diff) | |
download | hdf5-7d8ceade335c6528ba4cdbb386c36e918e02ee44.zip hdf5-7d8ceade335c6528ba4cdbb386c36e918e02ee44.tar.gz hdf5-7d8ceade335c6528ba4cdbb386c36e918e02ee44.tar.bz2 |
[svn-r17976] Bug fix for 1584. H5Tdetect_class said a VL string is a string type. But when it's in a
compound type, it says it's a VL type. We want to tell user a VL string is a string. But
internally we treat it as a VL type. I added a flag as a parameter of H5T_detect_class. It
tells whether the caller is the public function H5Tdetect_class. I also added a detection for
VL string in the private function for the compound case (or array or nested VL type).
Tested with h5committest.
Diffstat (limited to 'src/H5Dint.c')
-rw-r--r-- | src/H5Dint.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/H5Dint.c b/src/H5Dint.c index b92200b..c11c7bd 100644 --- a/src/H5Dint.c +++ b/src/H5Dint.c @@ -736,7 +736,7 @@ H5D_update_oh_info(H5F_t *file, hid_t dxpl_id, H5D_t *dset, hid_t dapl_id) HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't tell if fill value defined") /* Special case handling for variable-length types */ - if(H5T_detect_class(type, H5T_VLEN)) { + if(H5T_detect_class(type, H5T_VLEN, FALSE)) { /* If the default fill value is chosen for variable-length types, always write it */ if(fill_prop->fill_time == H5D_FILL_TIME_IFSET && fill_status == H5D_FILL_VALUE_DEFAULT) { /* Update dataset creation property */ @@ -927,7 +927,7 @@ H5D_create(H5F_t *file, hid_t type_id, const H5S_t *space, hid_t dcpl_id, HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, NULL, "datatype is not sensible") /* Check if the datatype is/contains a VL-type */ - if(H5T_detect_class(type, H5T_VLEN)) + if(H5T_detect_class(type, H5T_VLEN, FALSE)) has_vl_type = TRUE; /* Check if the dataspace has an extent set (or is NULL) */ |