diff options
author | Vailin Choi <vchoi@jam.ad.hdfgroup.org> | 2017-03-07 15:59:39 (GMT) |
---|---|---|
committer | Vailin Choi <vchoi@jam.ad.hdfgroup.org> | 2017-03-07 15:59:39 (GMT) |
commit | d5fea5b80a2ccc21fb4f187d0efeda80b9134156 (patch) | |
tree | 8cc95b236a40ce0567887d189bc077136cf0e2e6 /src/H5Dint.c | |
parent | 503ab9d88d6fb4b0866cb8bb77ee1df68dd735c1 (diff) | |
download | hdf5-d5fea5b80a2ccc21fb4f187d0efeda80b9134156.zip hdf5-d5fea5b80a2ccc21fb4f187d0efeda80b9134156.tar.gz hdf5-d5fea5b80a2ccc21fb4f187d0efeda80b9134156.tar.bz2 |
Bring fix for HDFFV-9697 from develop branch.
Populate the fix for HDFFV-9697: Fix for unknown message from develop branch.
Tested on ostrich, platypus, kite, quail, osx1010test, emu, mayll, moohan, kituo.
Diffstat (limited to 'src/H5Dint.c')
-rw-r--r-- | src/H5Dint.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/H5Dint.c b/src/H5Dint.c index 16ced02..b5adfc4 100644 --- a/src/H5Dint.c +++ b/src/H5Dint.c @@ -869,16 +869,22 @@ H5D__update_oh_info(H5F_t *file, hid_t dxpl_id, H5D_t *dset, hid_t dapl_id) if(NULL == (dc_plist = (H5P_genplist_t *)H5I_object(dset->shared->dcpl_id))) HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "can't get dataset creation property list") - /* Check whether to add a "bogus" message */ - if(H5P_exist_plist(dc_plist, H5O_BOGUS_MSG_FLAGS_NAME) > 0) { + /* Check whether to add a "bogus" message */ + if( (H5P_exist_plist(dc_plist, H5O_BOGUS_MSG_FLAGS_NAME) > 0) && + (H5P_exist_plist(dc_plist, H5O_BOGUS_MSG_ID_NAME) > 0) ) { + uint8_t bogus_flags = 0; /* Flags for creating "bogus" message */ + unsigned bogus_id; /* "bogus" ID */ + /* Retrieve "bogus" message ID */ + if(H5P_get(dc_plist, H5O_BOGUS_MSG_ID_NAME, &bogus_id) < 0) + HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't get bogus ID options") /* Retrieve "bogus" message flags */ if(H5P_get(dc_plist, H5O_BOGUS_MSG_FLAGS_NAME, &bogus_flags) < 0) HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't get bogus message options") /* Add a "bogus" message (for error testing). */ - if(H5O_bogus_oh(file, dxpl_id, oh, (unsigned)bogus_flags) < 0) + if(H5O_bogus_oh(file, dxpl_id, oh, bogus_id, (unsigned)bogus_flags) < 0) HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to create 'bogus' message") } /* end if */ } |