From db9b025d8554b47b295783715a8f7d2b1674d511 Mon Sep 17 00:00:00 2001 From: Raymond Lu Date: Wed, 10 Aug 2011 11:14:05 -0500 Subject: [svn-r21205] Issue 2763 - adding OAPL_ID as a new parameter to H5Rdereference. I added a check of OAPL_ID against -1 because CMAKE on 64-bit Windows slipped through the function call in the trefer.c test. Tested on jam and CMAKE on 64-bit Windows. --- src/H5R.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/H5R.c b/src/H5R.c index 68ddc91..aa5ad36 100644 --- a/src/H5R.c +++ b/src/H5R.c @@ -502,6 +502,7 @@ done: hid_t H5Rdereference2(ref) hid_t id; IN: Dataset reference object is in or location ID of object that the dataset is located within. + hid_t oapl_id; IN: Property list of the object being referenced. H5R_type_t ref_type; IN: Type of reference to create void *ref; IN: Reference to open. @@ -532,6 +533,8 @@ H5Rdereference2(hid_t obj_id, hid_t oapl_id, H5R_type_t ref_type, const void *_r /* Check args */ if(H5G_loc(obj_id, &loc) < 0) HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location") + if(oapl_id < 0) + HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a property list") if(ref_type <= H5R_BADTYPE || ref_type >= H5R_MAXTYPE) HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid reference type") if(_ref == NULL) -- cgit v0.12