diff options
Diffstat (limited to 'src/H5Iint.c')
-rw-r--r-- | src/H5Iint.c | 80 |
1 files changed, 40 insertions, 40 deletions
diff --git a/src/H5Iint.c b/src/H5Iint.c index 8a6b7ae..5715583 100644 --- a/src/H5Iint.c +++ b/src/H5Iint.c @@ -136,7 +136,7 @@ H5I_term_package(void) for (i = 0; i < H5I_next_type_g; i++) { type_info = H5I_type_info_array_g[i]; if (type_info) { - HDassert(NULL == type_info->hash_table); + assert(NULL == type_info->hash_table); type_info = H5MM_xfree(type_info); H5I_type_info_array_g[i] = NULL; in_use++; @@ -167,8 +167,8 @@ H5I_register_type(const H5I_class_t *cls) FUNC_ENTER_NOAPI(FAIL) /* Sanity check */ - HDassert(cls); - HDassert(cls->type > 0 && (int)cls->type < H5I_MAX_NUM_TYPES); + assert(cls); + assert(cls->type > 0 && (int)cls->type < H5I_MAX_NUM_TYPES); /* Initialize the type */ if (NULL == H5I_type_info_array_g[cls->type]) { @@ -260,7 +260,7 @@ H5I__unwrap(void *object, H5I_type_t type) FUNC_ENTER_PACKAGE_NOERR /* Sanity checks */ - HDassert(object); + assert(object); /* The stored object pointer might be an H5VL_object_t, in which * case we'll need to get the wrapped object struct (H5F_t *, etc.). @@ -372,9 +372,9 @@ H5I__mark_node(void *_info, void H5_ATTR_UNUSED *key, void *_udata) FUNC_ENTER_PACKAGE_NOERR /* Sanity checks */ - HDassert(info); - HDassert(udata); - HDassert(udata->type_info); + assert(info); + assert(udata); + assert(udata->type_info); /* Do nothing to the object if the reference count is larger than * one and forcing is off. @@ -388,10 +388,10 @@ H5I__mark_node(void *_info, void H5_ATTR_UNUSED *key, void *_udata) if (udata->force) { #ifdef H5I_DEBUG if (H5DEBUG(I)) { - HDfprintf(H5DEBUG(I), - "H5I: discard type=%d obj=%p " - "failure ignored\n", - (int)udata->type_info->cls->type, info->object); + fprintf(H5DEBUG(I), + "H5I: discard type=%d obj=%p " + "failure ignored\n", + (int)udata->type_info->cls->type, info->object); } #endif /* H5I_DEBUG */ @@ -411,10 +411,10 @@ H5I__mark_node(void *_info, void H5_ATTR_UNUSED *key, void *_udata) if (udata->force) { #ifdef H5I_DEBUG if (H5DEBUG(I)) { - HDfprintf(H5DEBUG(I), - "H5I: free type=%d obj=%p " - "failure ignored\n", - (int)udata->type_info->cls->type, info->object); + fprintf(H5DEBUG(I), + "H5I: free type=%d obj=%p " + "failure ignored\n", + (int)udata->type_info->cls->type, info->object); } #endif /* H5I_DEBUG */ @@ -551,7 +551,7 @@ H5I__register(H5I_type_t type, const void *object, hbool_t app_ref, H5I_future_r type_info->nextid++; /* Sanity check for the 'nextid' getting too large and wrapping around */ - HDassert(type_info->nextid <= ID_MASK); + assert(type_info->nextid <= ID_MASK); /* Set the most recent ID to this object */ type_info->last_id_info = info; @@ -581,8 +581,8 @@ H5I_register(H5I_type_t type, const void *object, hbool_t app_ref) FUNC_ENTER_NOAPI(H5I_INVALID_HID) /* Sanity checks */ - HDassert(type >= H5I_FILE && type < H5I_NTYPES); - HDassert(object); + assert(type >= H5I_FILE && type < H5I_NTYPES); + assert(object); /* Retrieve ID for object */ if (H5I_INVALID_HID == (ret_value = H5I__register(type, object, app_ref, NULL, NULL))) @@ -620,7 +620,7 @@ H5I_register_using_existing_id(H5I_type_t type, void *object, hbool_t app_ref, h FUNC_ENTER_NOAPI(FAIL) /* Check arguments */ - HDassert(object); + assert(object); /* Make sure ID is not already in use */ if (NULL != (info = H5I__find_id(existing_id))) @@ -760,7 +760,7 @@ H5I_object_verify(hid_t id, H5I_type_t type) FUNC_ENTER_NOAPI_NOERR - HDassert(type >= 1 && (int)type < H5I_next_type_g); + assert(type >= 1 && (int)type < H5I_next_type_g); /* Verify that the type of the ID is correct & lookup the ID */ if (type == H5I_TYPE(id) && NULL != (info = H5I__find_id(id))) { @@ -801,7 +801,7 @@ H5I_get_type(hid_t id) if (id > 0) ret_value = H5I_TYPE(id); - HDassert(ret_value >= H5I_BADID && (int)ret_value < H5I_next_type_g); + assert(ret_value >= H5I_BADID && (int)ret_value < H5I_next_type_g); FUNC_LEAVE_NOAPI(ret_value) } /* end H5I_get_type() */ @@ -910,12 +910,12 @@ H5I__remove_common(H5I_type_info_t *type_info, hid_t id) FUNC_ENTER_PACKAGE /* Sanity check */ - HDassert(type_info); + assert(type_info); /* Delete or mark the node */ HASH_FIND(hh, type_info->hash_table, &id, sizeof(hid_t), info); if (info) { - HDassert(!info->marked); + assert(!info->marked); if (!H5I_marking_g) HASH_DELETE(hh, type_info->hash_table, info); else @@ -1004,7 +1004,7 @@ H5I__dec_ref(hid_t id, void **request) FUNC_ENTER_PACKAGE /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* General lookup of the ID */ if (NULL == (info = H5I__find_id(id))) @@ -1068,7 +1068,7 @@ H5I_dec_ref(hid_t id) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* Synchronously decrement refcount on ID */ if ((ret_value = H5I__dec_ref(id, H5_REQUEST_NULL)) < 0) @@ -1100,7 +1100,7 @@ H5I__dec_app_ref(hid_t id, void **request) FUNC_ENTER_PACKAGE /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* Call regular decrement reference count routine */ if ((ret_value = H5I__dec_ref(id, request)) < 0) @@ -1116,7 +1116,7 @@ H5I__dec_app_ref(hid_t id, void **request) /* Adjust app_ref */ --(info->app_count); - HDassert(info->count >= info->app_count); + assert(info->count >= info->app_count); /* Set return value */ ret_value = (int)info->app_count; @@ -1148,7 +1148,7 @@ H5I_dec_app_ref(hid_t id) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* Synchronously decrement refcount on ID */ if ((ret_value = H5I__dec_app_ref(id, H5_REQUEST_NULL)) < 0) @@ -1183,7 +1183,7 @@ H5I_dec_app_ref_async(hid_t id, void **token) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* [Possibly] aynchronously decrement refcount on ID */ if ((ret_value = H5I__dec_app_ref(id, token)) < 0) @@ -1215,7 +1215,7 @@ H5I__dec_app_ref_always_close(hid_t id, void **request) FUNC_ENTER_PACKAGE /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* Call application decrement reference count routine */ ret_value = H5I__dec_app_ref(id, request); @@ -1256,7 +1256,7 @@ H5I_dec_app_ref_always_close(hid_t id) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* Synchronously decrement refcount on ID */ if ((ret_value = H5I__dec_app_ref_always_close(id, H5_REQUEST_NULL)) < 0) @@ -1288,7 +1288,7 @@ H5I_dec_app_ref_always_close_async(hid_t id, void **token) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* [Possibly] aynchronously decrement refcount on ID */ if ((ret_value = H5I__dec_app_ref_always_close(id, token)) < 0) @@ -1317,7 +1317,7 @@ H5I_inc_ref(hid_t id, hbool_t app_ref) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* General lookup of the ID */ if (NULL == (info = H5I__find_id(id))) @@ -1354,7 +1354,7 @@ H5I_get_ref(hid_t id, hbool_t app_ref) FUNC_ENTER_NOAPI((-1)) /* Sanity check */ - HDassert(id >= 0); + assert(id >= 0); /* General lookup of the ID */ if (NULL == (info = H5I__find_id(id))) @@ -1386,7 +1386,7 @@ H5I__inc_type_ref(H5I_type_t type) FUNC_ENTER_PACKAGE /* Sanity check */ - HDassert(type > 0 && (int)type < H5I_next_type_g); + assert(type > 0 && (int)type < H5I_next_type_g); /* Check arguments */ type_info = H5I_type_info_array_g[type]; @@ -1472,7 +1472,7 @@ H5I__get_type_ref(H5I_type_t type) FUNC_ENTER_PACKAGE /* Sanity check */ - HDassert(type >= 0); + assert(type >= 0); /* Check arguments */ type_info = H5I_type_info_array_g[type]; @@ -1662,7 +1662,7 @@ H5I__find_id(hid_t id) /* Swap the actual object in for the future object */ future_object = (void *)id_info->object; actual_object = H5I__remove_common(type_info, actual_id); - HDassert(actual_object); + assert(actual_object); id_info->object = actual_object; /* Discard the future object */ @@ -1706,8 +1706,8 @@ H5I__find_id_cb(void *_item, void H5_ATTR_UNUSED *_key, void *_udata) FUNC_ENTER_PACKAGE_NOERR /* Sanity check */ - HDassert(info); - HDassert(udata); + assert(info); + assert(udata); /* Get a pointer to the VOL connector's data */ H5_GCC_CLANG_DIAG_OFF("cast-qual") @@ -1742,7 +1742,7 @@ H5I_find_id(const void *object, H5I_type_t type, hid_t *id) FUNC_ENTER_NOAPI(FAIL) - HDassert(id); + assert(id); *id = H5I_INVALID_HID; |