diff options
author | Mohamad Chaarawi <chaarawi@hdfgroup.org> | 2014-04-02 18:47:48 (GMT) |
---|---|---|
committer | Mohamad Chaarawi <chaarawi@hdfgroup.org> | 2014-04-02 18:47:48 (GMT) |
commit | 294682e3acaeebbfe7ff7a0afaeb0aa4d1bf8f0c (patch) | |
tree | 13681636a1584e61e6d72d91bb66080a060b7cc3 | |
parent | 655603506dd03cc42c21332bde26673489997092 (diff) | |
download | hdf5-294682e3acaeebbfe7ff7a0afaeb0aa4d1bf8f0c.zip hdf5-294682e3acaeebbfe7ff7a0afaeb0aa4d1bf8f0c.tar.gz hdf5-294682e3acaeebbfe7ff7a0afaeb0aa4d1bf8f0c.tar.bz2 |
[svn-r24949] change the H5E macros at the server.
-rw-r--r-- | src/H5VLiod_analysis.c | 187 | ||||
-rw-r--r-- | src/H5VLiod_attr.c | 202 | ||||
-rw-r--r-- | src/H5VLiod_dset.c | 226 | ||||
-rw-r--r-- | src/H5VLiod_dtype.c | 76 | ||||
-rw-r--r-- | src/H5VLiod_file.c | 152 | ||||
-rw-r--r-- | src/H5VLiod_group.c | 52 | ||||
-rw-r--r-- | src/H5VLiod_index.c | 38 | ||||
-rw-r--r-- | src/H5VLiod_link.c | 112 | ||||
-rw-r--r-- | src/H5VLiod_map.c | 160 | ||||
-rw-r--r-- | src/H5VLiod_obj.c | 212 | ||||
-rw-r--r-- | src/H5VLiod_server.c | 790 | ||||
-rw-r--r-- | src/H5VLiod_server.h | 9 | ||||
-rw-r--r-- | src/H5VLiod_trans.c | 56 | ||||
-rw-r--r-- | src/H5VLiod_util.c | 202 | ||||
-rw-r--r-- | src/H5VLiod_view.c | 140 |
15 files changed, 1307 insertions, 1307 deletions
diff --git a/src/H5VLiod_analysis.c b/src/H5VLiod_analysis.c index 00f200f..3d088c3 100644 --- a/src/H5VLiod_analysis.c +++ b/src/H5VLiod_analysis.c @@ -18,7 +18,6 @@ */ #include "H5VLiod_server.h" - #include "H5Qpublic.h" #include "H5Vpublic.h" @@ -132,18 +131,18 @@ H5VL__iod_load_script(const char *script, const char *func_name) /* Get reference to main */ if(NULL == (po_main = PyImport_AddModule("__main__"))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, NULL, "can't get reference to main module"); + HGOTO_ERROR_FF(NULL, "can't get reference to main module"); if(NULL == (po_main_dict = PyModule_GetDict(po_main))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, NULL, "can't get dictionary from main module"); + HGOTO_ERROR_FF(NULL, "can't get dictionary from main module"); /* Load script */ if(NULL == (po_rstring = PyRun_String(script, Py_file_input, po_main_dict, po_main_dict))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, NULL, "can't load script into main module"); + HGOTO_ERROR_FF(NULL, "can't load script into main module"); /* Get reference to function name */ if(NULL == (po_func = PyObject_GetAttrString(po_main, func_name))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, NULL, "can't get reference to function"); + HGOTO_ERROR_FF(NULL, "can't get reference to function"); ret_value = po_func; @@ -171,7 +170,7 @@ H5VL__iod_translate_h5_type(hid_t data_type_id, enum NPY_TYPES *npy_type) hid_t native_datatype_id; if((native_datatype_id = H5Tget_native_type(data_type_id, H5T_DIR_DEFAULT)) < 0) - HGOTO_ERROR2(H5E_ARGS, H5E_BADTYPE, FAIL, "cannot retrieve native type"); + HGOTO_ERROR_FF(FAIL, "cannot retrieve native type"); if(H5Tequal(native_datatype_id, H5T_NATIVE_LLONG_g)) translated_type = NPY_LONGLONG; @@ -188,10 +187,10 @@ H5VL__iod_translate_h5_type(hid_t data_type_id, enum NPY_TYPES *npy_type) else if(H5Tequal(native_datatype_id, H5T_NATIVE_FLOAT_g)) translated_type = NPY_FLOAT; else - HGOTO_ERROR2(H5E_ARGS, H5E_BADTYPE, FAIL, "not a valid type") + HGOTO_ERROR_FF(FAIL, "not a valid type") if(FAIL == H5Tclose(native_datatype_id)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTFREE, FAIL, "unable to free datatype"); + HGOTO_ERROR_FF(FAIL, "unable to free datatype"); *npy_type = translated_type; @@ -240,12 +239,12 @@ H5VL__iod_translate_numpy_type(enum NPY_TYPES npy_type, hid_t *data_type_id, translated_type_id = H5T_NATIVE_FLOAT_g; break; default: - HGOTO_ERROR2(H5E_ARGS, H5E_BADTYPE, FAIL, "not a valid type") + HGOTO_ERROR_FF(FAIL, "not a valid type") break; } if (0 == (translated_type_size = H5Tget_size(translated_type_id))) - HGOTO_ERROR2(H5E_ARGS, H5E_BADTYPE, FAIL, "not a valid size") + HGOTO_ERROR_FF(FAIL, "not a valid size") *data_type_id = translated_type_id; *data_type_size = translated_type_size; @@ -275,7 +274,7 @@ H5VL__iod_create_numpy_array(size_t num_elmts, hid_t data_type_id, void *data) /* Convert data_type to numpy type */ if(FAIL == H5VL__iod_translate_h5_type(data_type_id, &npy_type)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTCONVERT, NULL, "unable to translate datatype to NPY type"); + HGOTO_ERROR_FF(NULL, "unable to translate datatype to NPY type"); ret_value = PyArray_SimpleNewFromData(1, dim, npy_type, data); @@ -311,26 +310,26 @@ H5VL__iod_extract_numpy_array(PyObject *numpy_array, void **data, /* Input array should be 1D */ if(PyArray_NDIM(numpy_array) > 1) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "was expecting 1-dimensional array") + HGOTO_ERROR_FF(FAIL, "was expecting 1-dimensional array") if(NULL == (numpy_data = PyArray_DATA(numpy_array))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get data from numpy array") + HGOTO_ERROR_FF(FAIL, "can't get data from numpy array") if(NULL == (numpy_dims = PyArray_DIMS(numpy_array))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get dimensions from numpy array") + HGOTO_ERROR_FF(FAIL, "can't get dimensions from numpy array") numpy_num_elmts = (size_t) numpy_dims[0]; if(0 == (numpy_datatype = PyArray_TYPE(numpy_array))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get type from numpy array") + HGOTO_ERROR_FF(FAIL, "can't get type from numpy array") /* Translate NPY type to hid_t */ if(FAIL == H5VL__iod_translate_numpy_type(numpy_datatype, &extracted_datatype_id, &extracted_datatype_size)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTCONVERT, FAIL, "can't translate NPY type") + HGOTO_ERROR_FF(FAIL, "can't translate NPY type") /* Copy data from NPY array */ if(NULL == (extracted_data = H5MM_malloc(numpy_num_elmts * extracted_datatype_size))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTALLOC, FAIL, "can't allocate extracted data") + HGOTO_ERROR_FF(FAIL, "can't allocate extracted data") HDmemcpy(extracted_data, numpy_data, numpy_num_elmts * extracted_datatype_size); *data = extracted_data; @@ -365,28 +364,28 @@ H5VL__iod_split(const char *split_script, void *data, size_t num_elmts, /* Create numpy array */ if(NULL == (po_numpy_array = H5VL__iod_create_numpy_array(num_elmts, data_type_id, data))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTCREATE, FAIL, "can't create numpy array from data") + HGOTO_ERROR_FF(FAIL, "can't create numpy array from data") /* Load script */ if(NULL == (po_func = H5VL__iod_load_script(split_script, "split"))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, FAIL, "can't load split script") + HGOTO_ERROR_FF(FAIL, "can't load split script") /* Check whether split is defined as function in given script */ if(0 == PyCallable_Check(po_func)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, FAIL, "can't find split function") + HGOTO_ERROR_FF(FAIL, "can't find split function") /* Get the input to function */ if(NULL == (po_args_tup = PyTuple_Pack(1, po_numpy_array))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, FAIL, "can't set input to split function") + HGOTO_ERROR_FF(FAIL, "can't set input to split function") /* Invoke the split function */ if(NULL == (po_numpy_array_split = PyObject_CallObject(po_func, po_args_tup))) - HGOTO_ERROR2(H5E_SYM, H5E_BADVALUE, FAIL, "returned NULL python object") + HGOTO_ERROR_FF(FAIL, "returned NULL python object") /* Extract data from numpy array */ if(FAIL == H5VL__iod_extract_numpy_array(po_numpy_array_split, split_data, split_num_elmts, split_data_type_id)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTCREATE, FAIL, "can't extract data from numpy array") + HGOTO_ERROR_FF(FAIL, "can't extract data from numpy array") done: /* Cleanup */ @@ -423,7 +422,7 @@ H5VL__iod_combine(const char *combine_script, void **split_data, size_t *split_n /* Create numpy arrays */ if(NULL == (po_numpy_arrays = PyList_New((Py_ssize_t) num_targets))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTCREATE, FAIL, "can't create list of arrays") + HGOTO_ERROR_FF(FAIL, "can't create list of arrays") for(i = 0; i < num_targets; i++) { PyObject *po_numpy_array = NULL; int py_ret = 0; @@ -432,32 +431,32 @@ H5VL__iod_combine(const char *combine_script, void **split_data, size_t *split_n H5VL__iod_create_numpy_array(split_num_elmts[i], data_type_id, split_data[i]))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTCREATE, FAIL, "can't create numpy array from data") + HGOTO_ERROR_FF(FAIL, "can't create numpy array from data") if(0 != (py_ret = PyList_SetItem(po_numpy_arrays, (Py_ssize_t) i, po_numpy_array))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't set item to array list") + HGOTO_ERROR_FF(FAIL, "can't set item to array list") } /* Load script */ if(NULL == (po_func = H5VL__iod_load_script(combine_script, "combine"))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, FAIL, "can't load combine script") + HGOTO_ERROR_FF(FAIL, "can't load combine script") /* Check whether split is defined as function in given script */ if(0 == PyCallable_Check(po_func)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, FAIL, "can't find combine function") + HGOTO_ERROR_FF(FAIL, "can't find combine function") /* Get the input to function */ if(NULL == (po_args_tup = PyTuple_Pack(1, po_numpy_arrays))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTLOAD, FAIL, "can't set input to combine function") + HGOTO_ERROR_FF(FAIL, "can't set input to combine function") /* Invoke the split function */ if(NULL == (po_numpy_array_combine = PyObject_CallObject(po_func, po_args_tup))) - HGOTO_ERROR2(H5E_SYM, H5E_BADVALUE, FAIL, "returned NULL python object") + HGOTO_ERROR_FF(FAIL, "returned NULL python object") /* Extract data from numpy array */ if(FAIL == H5VL__iod_extract_numpy_array(po_numpy_array_combine, combine_data, combine_num_elmts, combine_data_type_id)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTCREATE, FAIL, "can't extract data from numpy array") + HGOTO_ERROR_FF(FAIL, "can't extract data from numpy array") done: /* Cleanup */ @@ -492,30 +491,30 @@ H5VL__iod_request_container_open(const char *file_name, iod_handle_t **cohs) int i; if(NULL == (hg_reqs = (hg_request_t *)malloc(sizeof(hg_request_t) * (unsigned int) num_ions_g))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate HG requests"); + HGOTO_ERROR_FF(FAIL, "can't allocate HG requests"); if(NULL == (temp_cohs = (iod_handle_t *)malloc(sizeof(iod_handle_t) * (unsigned int) num_ions_g))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate container handles"); + HGOTO_ERROR_FF(FAIL, "can't allocate container handles"); /* forward a call to every ION to open the container */ for(i = 1; i < num_ions_g; i++) { if(HG_Forward(server_addr_g[i], H5VL_EFF_OPEN_CONTAINER, &file_name, &temp_cohs[i], &hg_reqs[i]) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to ship operation"); + HGOTO_ERROR_FF(FAIL, "failed to ship operation"); } /* open the container */ printf("(%d) Calling iod_container_open on %s\n", my_rank_g, file_name); if(iod_container_open(file_name, NULL, IOD_CONT_R, &temp_cohs[0], NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open file"); + HGOTO_ERROR_FF(FAIL, "can't open file"); for(i = 1; i < num_ions_g; i++) { if(HG_Wait(hg_reqs[i], HG_MAX_IDLE_TIME, HG_STATUS_IGNORE) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "HG_Wait Failed"); + HGOTO_ERROR_FF(FAIL, "HG_Wait Failed"); /* Free Mercury request */ if(HG_Request_free(hg_reqs[i]) != HG_SUCCESS) - HGOTO_ERROR2(H5E_SYM, H5E_CANTFREE, FAIL, "Can't Free Mercury Request"); + HGOTO_ERROR_FF(FAIL, "Can't Free Mercury Request"); } free(hg_reqs); @@ -543,26 +542,26 @@ H5VL__iod_request_container_close(iod_handle_t *cohs) int i; if(NULL == (hg_reqs = (hg_request_t *)malloc(sizeof(hg_request_t) * (unsigned int) num_ions_g))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate HG requests"); + HGOTO_ERROR_FF(FAIL, "can't allocate HG requests"); /* forward a call to every ION to close the container */ for(i = 1; i < num_ions_g; i++) { if(HG_Forward(server_addr_g[i], H5VL_EFF_CLOSE_CONTAINER, &cohs[i], &ret_value, &hg_reqs[i]) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to ship operation"); + HGOTO_ERROR_FF(FAIL, "failed to ship operation"); } /* close the container */ if(iod_container_close(cohs[0], NULL, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTDEC, FAIL, "can't close container"); + HGOTO_ERROR_FF(FAIL, "can't close container"); for(i = 1; i < num_ions_g; i++) { if(HG_Wait(hg_reqs[i], HG_MAX_IDLE_TIME, HG_STATUS_IGNORE) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "HG_Wait Failed"); + HGOTO_ERROR_FF(FAIL, "HG_Wait Failed"); /* Free Mercury request */ if(HG_Request_free(hg_reqs[i]) != HG_SUCCESS) - HGOTO_ERROR2(H5E_SYM, H5E_CANTFREE, FAIL, "Can't Free Mercury Request"); + HGOTO_ERROR_FF(FAIL, "Can't Free Mercury Request"); } free(hg_reqs); free(cohs); @@ -601,16 +600,16 @@ H5VL__iod_farm_work(iod_obj_map_t *obj_map, iod_handle_t *cohs, /* function shipper requests */ if(NULL == (hg_reqs = (hg_request_t *) malloc(sizeof(hg_request_t) * num_targets))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate HG requests"); + HGOTO_ERROR_FF(FAIL, "can't allocate HG requests"); if(NULL == (farm_output = (analysis_farm_out_t *) malloc(sizeof(analysis_farm_out_t) * num_targets))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate HG requests"); + HGOTO_ERROR_FF(FAIL, "can't allocate HG requests"); if(NULL == (split_data = (void **) malloc(sizeof(void *) * num_targets))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate array for split data"); + HGOTO_ERROR_FF(FAIL, "can't allocate array for split data"); if(NULL == (split_num_elmts = (size_t *) malloc(sizeof(size_t) * num_targets))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate array for num elmts"); + HGOTO_ERROR_FF(FAIL, "can't allocate array for num elmts"); farm_input.obj_id = obj_id; farm_input.rtid = rtid; @@ -646,12 +645,12 @@ H5VL__iod_farm_work(iod_obj_map_t *obj_map, iod_handle_t *cohs, if(FAIL == H5VL__iod_farm_split(cohs[0], obj_id, rtid, space_id, farm_input.coords, farm_input.num_cells, type_id, query_id, split_script, &split_data[i], &split_num_elmts[i], &split_type_id)) - HGOTO_ERROR2(H5E_ATTR, H5E_WRITEERROR, FAIL, "can't split in farmed job"); + HGOTO_ERROR_FF(FAIL, "can't split in farmed job"); } else { if(HG_Forward(server_addr_g[server_idx], H5VL_EFF_ANALYSIS_FARM, &farm_input, &farm_output[i], &hg_reqs[i]) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to ship operation"); + HGOTO_ERROR_FF(FAIL, "failed to ship operation"); } } @@ -667,7 +666,7 @@ H5VL__iod_farm_work(iod_obj_map_t *obj_map, iod_handle_t *cohs, /* Wait for the farmed work to complete */ if(HG_Wait(hg_reqs[i], HG_MAX_IDLE_TIME, HG_STATUS_IGNORE) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "HG_Wait Failed"); + HGOTO_ERROR_FF(FAIL, "HG_Wait Failed"); /* Get split type ID and num_elemts (all the arrays should have the same native type id) */ server_idx = farm_output[i].server_idx; @@ -678,7 +677,7 @@ H5VL__iod_farm_work(iod_obj_map_t *obj_map, iod_handle_t *cohs, // split_num_elmts[i], H5Tget_size(split_type_id), server_idx); if(NULL == (split_data[i] = malloc(split_data_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate farm buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate farm buffer"); HG_Bulk_handle_create(split_data[i], split_data_size, HG_BULK_READWRITE, &bulk_handle); @@ -689,18 +688,18 @@ H5VL__iod_farm_work(iod_obj_map_t *obj_map, iod_handle_t *cohs, /* forward a free call to the target server */ if(HG_Forward(server_addr_g[server_idx], H5VL_EFF_ANALYSIS_FARM_TRANSFER, &transfer_input, &transfer_output, &hg_reqs[i]) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to ship operation"); + HGOTO_ERROR_FF(FAIL, "failed to ship operation"); /* Wait for the farmed work to complete */ if(HG_Wait(hg_reqs[i], HG_MAX_IDLE_TIME, HG_STATUS_IGNORE) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "HG_Wait Failed"); + HGOTO_ERROR_FF(FAIL, "HG_Wait Failed"); /* Free bulk handle */ HG_Bulk_handle_free(bulk_handle); /* Free Mercury request */ if(HG_Request_free(hg_reqs[i]) != HG_SUCCESS) - HGOTO_ERROR2(H5E_SYM, H5E_CANTFREE, FAIL, "Can't Free Mercury Request"); + HGOTO_ERROR_FF(FAIL, "Can't Free Mercury Request"); } } @@ -714,7 +713,7 @@ H5VL__iod_farm_work(iod_obj_map_t *obj_map, iod_handle_t *cohs, if (H5VL__iod_combine(combine_script, split_data, split_num_elmts, num_targets, split_type_id, &combine_data, &combine_num_elmts, &combine_type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't combine split data"); + HGOTO_ERROR_FF(FAIL, "can't combine split data"); #endif /* free farm data */ @@ -771,20 +770,20 @@ H5VL_iod_server_analysis_execute_cb(AXE_engine_t UNUSED axe_engine, /* ****************** TEMP THING (as IOD requires collective container open) */ if(FAIL == H5VL__iod_request_container_open(file_name, &cohs)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't request container open"); + HGOTO_ERROR_FF(FAIL, "can't request container open"); /* ***************** END TEMP THING */ if(iod_query_cont_trans_stat(cohs[0], &tids, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get container tids status"); + HGOTO_ERROR_FF(FAIL, "can't get container tids status"); rtid = tids->latest_rdable; if(iod_free_cont_trans_stat(cohs[0], tids) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free container transaction status object"); + HGOTO_ERROR_FF(FAIL, "can't free container transaction status object"); if(iod_trans_start(cohs[0], &rtid, NULL, 0, IOD_TRANS_R, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't start transaction"); + HGOTO_ERROR_FF(FAIL, "can't start transaction"); root_handle.rd_oh.cookie = IOD_OH_UNDEFINED; root_handle.wr_oh.cookie = IOD_OH_UNDEFINED; @@ -792,7 +791,7 @@ H5VL_iod_server_analysis_execute_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path to retrieve object ID, and open object */ if(H5VL_iod_server_open_path(cohs[0], ROOT_ID, root_handle, obj_name, rtid, 7, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); printf("(%d) coh %"PRIu64" objoh %"PRIu64" objid %"PRIx64" rtid %"PRIu64"\n", my_rank_g, cohs[0].cookie, obj_oh.rd_oh.cookie, obj_id, rtid); @@ -819,30 +818,30 @@ H5VL_iod_server_analysis_execute_cb(AXE_engine_t UNUSED axe_engine, /* get scratch pad */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, (char *) &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); /* retrieve datatype and dataspace */ /* MSC - This applies only to DATASETS for Q6 */ /* open the metadata scratch pad */ if (iod_obj_open_read(cohs[0], sp[0], rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, 7, NULL, &type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, 7, NULL, &space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); /*******************************************/ /* Farm work */ if(FAIL == H5VL__iod_farm_work(obj_map, cohs, obj_id, rtid, space_id, type_id, query_id, split_script, combine_script)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't farm work"); + HGOTO_ERROR_FF(FAIL, "can't farm work"); /********************************************/ @@ -850,19 +849,19 @@ H5VL_iod_server_analysis_execute_cb(AXE_engine_t UNUSED axe_engine, /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* close object */ if(iod_obj_close(obj_oh.rd_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); if(iod_trans_finish(cohs[0], rtid, NULL, 0, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't finish transaction 0"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction 0"); /* ****************** TEMP THING (as IOD requires collective container open) */ printf("Closing container\n"); if(FAIL == H5VL__iod_request_container_close(cohs)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't request container close"); + HGOTO_ERROR_FF(FAIL, "can't request container close"); /* ***************** END TEMP THING */ @@ -908,18 +907,18 @@ H5VL__iod_farm_split(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t rtid, hid_t space_layout; if(FAIL == (space_layout = H5VL__iod_get_space_layout(coords, num_cells, space_id))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't generate local dataspace selection"); + HGOTO_ERROR_FF(FAIL, "can't generate local dataspace selection"); if(H5VL__iod_get_query_data(coh, obj_id, rtid, query_id, space_layout, type_id, &num_elmts, &data) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read local data"); + HGOTO_ERROR_FF(FAIL, "can't read local data"); printf("(%d) Applying split on data\n", my_rank_g); /* Apply split python script on data from query */ #ifdef H5_HAVE_PYTHON if(FAIL == H5VL__iod_split(split_script, data, num_elmts, type_id, split_data, split_num_elmts, split_type_id)) - HGOTO_ERROR2(H5E_SYM, H5E_CANAPPLY, FAIL, "can't apply split script to data"); + HGOTO_ERROR_FF(FAIL, "can't apply split script to data"); #endif /* Free the data after split operation */ @@ -969,11 +968,11 @@ H5VL_iod_server_analysis_farm_cb(AXE_engine_t UNUSED axe_engine, if(FAIL == H5VL__iod_farm_split(coh, obj_id, rtid, space_id, coords, num_cells, type_id, query_id, split_script, &split_data, &split_num_elmts, &split_type_id)) - HGOTO_ERROR2(H5E_ATTR, H5E_WRITEERROR, FAIL, "can't split in farmed job"); + HGOTO_ERROR_FF(FAIL, "can't split in farmed job"); /* allocate output struct */ if(NULL == (output = (H5VLiod_farm_data_t *)H5MM_malloc(sizeof(H5VLiod_farm_data_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, FAIL, "No Space"); + HGOTO_ERROR_FF(FAIL, "No Space"); /* set output, and return to master */ output->farm_out.ret = ret_value; @@ -1019,7 +1018,7 @@ H5VL_iod_server_analysis_transfer_cb(AXE_engine_t axe_engine, na_addr_t source = HG_Handler_get_addr(op_data->hg_handle); if(AXE_SUCCEED != AXEget_op_data(axe_engine, input->axe_id, &farm_op_data_ptr)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to get farm op_data"); + HGOTO_ERROR_FF(FAIL, "failed to get farm op_data"); farm_op_data = (op_data_t *)farm_op_data_ptr; farm_output = (H5VLiod_farm_data_t *)farm_op_data->output; @@ -1033,15 +1032,15 @@ H5VL_iod_server_analysis_transfer_cb(AXE_engine_t axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(source, input->bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* free the bds block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); free(farm_output->data); farm_op_data = (op_data_t *)H5MM_xfree(farm_op_data); @@ -1080,7 +1079,7 @@ H5VL__iod_get_space_layout(coords_t coords, iod_size_t num_cells, hid_t space_id /* copy the original dataspace and reset selection to NONE */ if(FAIL == (space_layout = H5Scopy(space_id))) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTINIT, FAIL, "unable to copy dataspace"); + HGOTO_ERROR_FF(FAIL, "unable to copy dataspace"); for(i=0 ; i<ndims ; i++) { start[i] = coords.start_cell[i]; @@ -1089,14 +1088,14 @@ H5VL__iod_get_space_layout(coords_t coords, iod_size_t num_cells, hid_t space_id } if(H5Sselect_hyperslab(space_layout, H5S_SELECT_SET, start, NULL, count, block)) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTSET, FAIL, "unable to add point to selection"); + HGOTO_ERROR_FF(FAIL, "unable to add point to selection"); ret_value = space_layout; done: if(ret_value < 0) { if(FAIL != space_layout && H5Sclose(space_layout) < 0) - HDONE_ERROR2(H5E_DATASPACE, H5E_CANTRELEASE, FAIL, "unable to release dataspace") + HDONE_ERROR_FF(FAIL, "unable to release dataspace") } /* end if */ return ret_value; @@ -1121,7 +1120,7 @@ H5VL__iod_get_query_data_cb(void *elem, hid_t type_id, unsigned ndim, /* Apply the query */ if(H5Qapply(udata->query_id, &result, type_id, elem) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "unable to apply query to data element"); + HGOTO_ERROR_FF(FAIL, "unable to apply query to data element"); /* If element satisfies query, add it to the selection */ if (result) { @@ -1129,7 +1128,7 @@ H5VL__iod_get_query_data_cb(void *elem, hid_t type_id, unsigned ndim, printf("(%d) Element |%d| matches query\n", my_rank_g, *((int *) elem)); udata->num_elmts ++; if(H5Sselect_elements(udata->space_query, H5S_SELECT_APPEND, 1, point)) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTSET, FAIL, "unable to add point to selection") + HGOTO_ERROR_FF(FAIL, "unable to add point to selection") } done: @@ -1167,19 +1166,19 @@ H5VL__iod_get_query_data(iod_handle_t coh, iod_obj_id_t dset_id, /* allocate buffer to hold data */ if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* read the data local on the ION specified in the layout selection */ if(H5VL__iod_read_selection(coh, dset_id, rtid, space_id, type_id, buf) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read local data"); + HGOTO_ERROR_FF(FAIL, "can't read local data"); dims[0] = (hsize_t)nelmts; /* create a 1-D selection to describe the data read in memory */ if(FAIL == (mem_space = H5Screate_simple(1, dims, NULL))) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTCREATE, FAIL, "can't create simple dataspace"); + HGOTO_ERROR_FF(FAIL, "can't create simple dataspace"); if(FAIL == (space_query = H5Scopy(mem_space))) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTINIT, FAIL, "unable to copy dataspace"); + HGOTO_ERROR_FF(FAIL, "unable to copy dataspace"); udata.query_id = query_id; udata.space_query = space_query; @@ -1188,26 +1187,26 @@ H5VL__iod_get_query_data(iod_handle_t coh, iod_obj_id_t dset_id, /* iterate over every element and apply the query on it. If the query is not satisfied, then remove it from the query selection */ if(H5Diterate(buf, type_id, mem_space, H5VL__iod_get_query_data_cb, &udata) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to compute buffer size"); + HGOTO_ERROR_FF(FAIL, "failed to compute buffer size"); if(udata.num_elmts) { buf_size = udata.num_elmts * elmt_size; /* allocate buffer to hold data */ if(NULL == (*data = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate data buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate data buffer"); if(H5Dgather(space_query, buf, type_id, buf_size, *data, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_IO, H5E_CANTCOPY, FAIL, "gather failed") + HGOTO_ERROR_FF(FAIL, "gather failed") } *num_elmts = udata.num_elmts; done: if(space_query && H5Sclose(space_query) < 0) - HDONE_ERROR2(H5E_DATASPACE, H5E_CANTRELEASE, FAIL, "unable to release dataspace") + HDONE_ERROR_FF(FAIL, "unable to release dataspace") if(mem_space && H5Sclose(mem_space) < 0) - HDONE_ERROR2(H5E_DATASPACE, H5E_CANTRELEASE, FAIL, "unable to release dataspace") + HDONE_ERROR_FF(FAIL, "unable to release dataspace") if(buf != NULL) free(buf); @@ -1236,19 +1235,19 @@ H5VL__iod_read_selection(iod_handle_t coh, iod_obj_id_t obj_id, /* open the array object */ if (iod_obj_open_read(coh, obj_id, rtid, NULL, &obj_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open array object fo read"); + HGOTO_ERROR_FF(FAIL, "can't open array object fo read"); /* read the data selection from IOD. */ /* MSC - will need to do it in pieces, not it one shot. */ elmt_size = H5Tget_size(type_id); if(H5VL__iod_server_final_io(obj_oh, space_id, elmt_size, FALSE, buf, buf_size, (uint64_t)0, 0, rtid) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); done: if(obj_oh.cookie != IOD_OH_UNDEFINED && iod_obj_close(obj_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); return ret_value; } /* end H5VL__iod_read_selection() */ diff --git a/src/H5VLiod_attr.c b/src/H5VLiod_attr.c index 0f8ee43..83b86fe 100644 --- a/src/H5VLiod_attr.c +++ b/src/H5VLiod_attr.c @@ -89,14 +89,14 @@ H5VL_iod_server_attr_create_cb(AXE_engine_t UNUSED axe_engine, if(loc_handle.rd_oh.cookie == IOD_OH_UNDEFINED) { /* Try and open the starting location */ if (iod_obj_open_read(coh, loc_id, wtid, NULL, &loc_handle.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open start location"); + HGOTO_ERROR_FF(FAIL, "can't open start location"); opened_locally = TRUE; } /* Open the object where the attribute needs to be created. */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* Set the IOD array creation parameters */ array.cell_size = (uint32_t)H5Tget_size(input->type_id); @@ -110,7 +110,7 @@ H5VL_iod_server_attr_create_cb(AXE_engine_t UNUSED axe_engine, } else { if(H5Sget_simple_extent_dims(input->space_id, current_dims, array_dims) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get dimentions' sizes"); + HGOTO_ERROR_FF(FAIL, "can't get dimentions' sizes"); array.firstdim_max = array_dims[0]; } @@ -120,16 +120,16 @@ H5VL_iod_server_attr_create_cb(AXE_engine_t UNUSED axe_engine, /* create the attribute */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_ARRAY, NULL, &array, &attr_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create Attribute"); + HGOTO_ERROR_FF(FAIL, "can't create Attribute"); if (iod_obj_open_read(coh, attr_id, wtid, NULL, &attr_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open attribute"); + HGOTO_ERROR_FF(FAIL, "can't open attribute"); if (iod_obj_open_write(coh, attr_id, wtid, NULL, &attr_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open attribute"); + HGOTO_ERROR_FF(FAIL, "can't open attribute"); /* create the metadata KV object for the attribute */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &mdkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* set values for the scratch pad object */ sp[0] = mdkv_id; @@ -141,31 +141,31 @@ H5VL_iod_server_attr_create_cb(AXE_engine_t UNUSED axe_engine, if(cs_scope & H5_CHECKSUM_IOD) { sp_cs = H5_checksum_crc64(&sp, sizeof(sp)); if (iod_obj_set_scratch(attr_oh.wr_oh, wtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } else { if (iod_obj_set_scratch(attr_oh.wr_oh, wtid, &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } /* Open Metadata KV object for write */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't create scratch pad"); /* insert object type metadata */ if(H5VL_iod_insert_object_type(mdkv_oh, wtid, H5I_ATTR, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* MSC - need to check size of datatype if it fits in entry otherwise create a BLOB */ /* insert datatype metadata */ if(H5VL_iod_insert_datatype(mdkv_oh, wtid, input->type_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert dataspace metadata */ if(H5VL_iod_insert_dataspace(mdkv_oh, wtid, input->space_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* if the starting location is not the last component, need to read the attrkv_id of the last object where attribute needs @@ -173,28 +173,28 @@ H5VL_iod_server_attr_create_cb(AXE_engine_t UNUSED axe_engine, if(loc_id != obj_id || loc_attrkv_id == IOD_OBJ_INVALID) { /* get scratch pad of the parent */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the attribute KV in scratch pad */ if (iod_obj_open_write(coh, sp[1], wtid, NULL /*hints*/, &attr_kv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } else { /* open the attribute KV */ if (iod_obj_open_write(coh, loc_attrkv_id, wtid, NULL /*hints*/, &attr_kv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } /* insert new attribute in scratch pad of current object */ if(H5VL_iod_insert_new_link(attr_kv_oh, wtid, attr_name, H5L_TYPE_HARD, &attr_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); output.iod_oh.rd_oh.cookie = attr_oh.rd_oh.cookie; output.iod_oh.wr_oh.cookie = attr_oh.wr_oh.cookie; @@ -222,10 +222,10 @@ done: if(attr_oh.rd_oh.cookie != IOD_OH_UNDEFINED && iod_obj_close(attr_oh.rd_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HDONE_ERROR_FF(FAIL, "can't close object"); if(attr_oh.wr_oh.cookie != IOD_OH_UNDEFINED && iod_obj_close(attr_oh.wr_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HDONE_ERROR_FF(FAIL, "can't close object"); output.iod_oh.rd_oh.cookie = IOD_OH_UNDEFINED; output.iod_oh.wr_oh.cookie = IOD_OH_UNDEFINED; @@ -241,12 +241,12 @@ done: /* close the Metadata KV object */ if(mdkv_oh.cookie != IOD_OH_UNDEFINED && iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HDONE_ERROR_FF(FAIL, "can't close object"); /* close the Attribute KV object */ if(attr_kv_oh.cookie != IOD_OH_UNDEFINED && iod_obj_close(attr_kv_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HDONE_ERROR_FF(FAIL, "can't close object"); #endif input = (attr_create_in_t *)H5MM_xfree(input); @@ -303,7 +303,7 @@ H5VL_iod_server_attr_open_cb(AXE_engine_t UNUSED axe_engine, /* Open the object where the attribute needs to be opened. */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); #if H5_EFF_DEBUG fprintf(stderr, "Attribute is on object (OH %"PRIu64" ID %"PRIx64")\n", @@ -316,32 +316,32 @@ H5VL_iod_server_attr_open_cb(AXE_engine_t UNUSED axe_engine, if(loc_id != obj_id || loc_attrkv_id == IOD_OBJ_INVALID) { /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* if attribute KV does not exist, return error*/ if(IOD_OBJ_INVALID == sp[1]) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "Object has no attributes"); + HGOTO_ERROR_FF(FAIL, "Object has no attributes"); /* open the attribute KV in scratch pad */ if (iod_obj_open_read(coh, sp[1], rtid, NULL /*hints*/, &attr_kv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } else { /* open the attribute KV */ if (iod_obj_open_read(coh, loc_attrkv_id, rtid, NULL /*hints*/, &attr_kv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } /* get attribute ID */ if(H5VL_iod_get_metadata(attr_kv_oh, rtid, H5VL_IOD_LINK, attr_name, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve Attribute ID from parent KV store"); + HGOTO_ERROR_FF(FAIL, "can't retrieve Attribute ID from parent KV store"); HDassert(iod_link.link_type == H5L_TYPE_HARD); attr_id = iod_link.u.iod_id; @@ -356,37 +356,37 @@ H5VL_iod_server_attr_open_cb(AXE_engine_t UNUSED axe_engine, /* open the attribute */ if (iod_obj_open_read(coh, attr_id, rtid, NULL /*hints*/, &attr_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); if (iod_obj_open_write(coh, attr_id, rtid, NULL /*hints*/, &attr_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); /* get scratch pad of the attribute */ if(iod_obj_get_scratch(attr_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad of the attribute */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, cs_scope, NULL, &output.type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &output.space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); output.iod_id = attr_id; output.mdkv_id = sp[0]; @@ -464,7 +464,7 @@ H5VL_iod_server_attr_read_cb(AXE_engine_t UNUSED axe_engine, /* open the attribute if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, iod_id, rtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } @@ -476,22 +476,22 @@ H5VL_iod_server_attr_read_cb(AXE_engine_t UNUSED axe_engine, size = HG_Bulk_handle_get_size(bulk_handle); if(NULL == (buf = malloc(size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* Get dataspace if it is not available */ if(H5I_UNINIT == space_id) { /* open the metadata scratch pad of the attribute */ if (iod_obj_open_read(coh, mdkv_id, rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } /* set the memory descriptor */ @@ -504,7 +504,7 @@ H5VL_iod_server_attr_read_cb(AXE_engine_t UNUSED axe_engine, /* get the rank of the dataspace */ if((ndims = H5Sget_simple_extent_ndims(space_id)) < 0) - HGOTO_ERROR2(H5E_INTERNAL, H5E_CANTGET, FAIL, "unable to get dataspace dimesnsion"); + HGOTO_ERROR_FF(FAIL, "unable to get dataspace dimesnsion"); /* handle scalar dataspace */ if(0 == ndims) { @@ -529,7 +529,7 @@ H5VL_iod_server_attr_read_cb(AXE_engine_t UNUSED axe_engine, /* generate the descriptor */ if(H5VL_iod_get_file_desc(space_id, &num_descriptors, &hslabs) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTGET, FAIL, "unable to generate IOD file descriptor from dataspace selection"); + HGOTO_ERROR_FF(FAIL, "unable to generate IOD file descriptor from dataspace selection"); } /* set the file descriptor */ @@ -541,19 +541,19 @@ H5VL_iod_server_attr_read_cb(AXE_engine_t UNUSED axe_engine, &iod_cs, NULL); if(ret < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); } attr_cs = H5_checksum_crc64(buf, size); if(attr_cs != iod_cs) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "Data corruption detected when reading attribute"); + HGOTO_ERROR_FF(FAIL, "Data corruption detected when reading attribute"); } else { ret = iod_array_read(iod_oh, rtid, NULL, mem_desc, &file_desc, NULL, NULL); if(ret < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); } } @@ -562,10 +562,10 @@ H5VL_iod_server_attr_read_cb(AXE_engine_t UNUSED axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(dest, bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't start Mercury Bulk Data write"); + HGOTO_ERROR_FF(FAIL, "can't start Mercury Bulk Data write"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "Failed to wait on Mercury Bulk data write"); + HGOTO_ERROR_FF(FAIL, "Failed to wait on Mercury Bulk data write"); done: #if H5_EFF_DEBUG @@ -573,9 +573,9 @@ done: #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't free bds block handle"); + HDONE_ERROR_FF(FAIL, "can't free bds block handle"); input = (attr_io_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -593,7 +593,7 @@ done: /* close the attribute if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_attr_read_cb() */ @@ -648,7 +648,7 @@ H5VL_iod_server_attr_write_cb(AXE_engine_t UNUSED axe_engine, /* open the attribute if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_write(coh, iod_id, wtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } @@ -660,34 +660,34 @@ H5VL_iod_server_attr_write_cb(AXE_engine_t UNUSED axe_engine, /* Read bulk data here and wait for the data to be here */ size = HG_Bulk_handle_get_size(bulk_handle); if(NULL == (buf = malloc(size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); HG_Bulk_handle_create(buf, size, HG_BULK_READWRITE, &bulk_block_handle); /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_read_all(source, bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* free the bds block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); /* Get dataspace if it is not available */ if(H5I_UNINIT == space_id) { /* open the metadata scratch pad of the attribute */ if (iod_obj_open_read(coh, mdkv_id, wtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } /* set the memory descriptor */ @@ -700,7 +700,7 @@ H5VL_iod_server_attr_write_cb(AXE_engine_t UNUSED axe_engine, /* get the rank of the dataspace */ if((ndims = H5Sget_simple_extent_ndims(space_id)) < 0) - HGOTO_ERROR2(H5E_INTERNAL, H5E_CANTGET, FAIL, "unable to get dataspace dimesnsion"); + HGOTO_ERROR_FF(FAIL, "unable to get dataspace dimesnsion"); /* handle scalar dataspace */ if(0 == ndims) { @@ -725,7 +725,7 @@ H5VL_iod_server_attr_write_cb(AXE_engine_t UNUSED axe_engine, /* generate the descriptor */ if(H5VL_iod_get_file_desc(space_id, &num_descriptors, &hslabs) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTGET, FAIL, "unable to generate IOD file descriptor from dataspace selection"); + HGOTO_ERROR_FF(FAIL, "unable to generate IOD file descriptor from dataspace selection"); } /* set the file descriptor */ @@ -735,12 +735,12 @@ H5VL_iod_server_attr_write_cb(AXE_engine_t UNUSED axe_engine, attr_cs = H5_checksum_crc64(buf, size); /* write from array object */ if(iod_array_write(iod_oh, wtid, NULL, mem_desc, &file_desc, &attr_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't write to array object"); + HGOTO_ERROR_FF(FAIL, "can't write to array object"); } else { /* write from array object */ if(iod_array_write(iod_oh, wtid, NULL, mem_desc, &file_desc, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't write to array object"); + HGOTO_ERROR_FF(FAIL, "can't write to array object"); } done: @@ -749,7 +749,7 @@ done: #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); input = (attr_io_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -767,7 +767,7 @@ done: /* close the attribute if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_attr_write_cb() */ @@ -816,17 +816,17 @@ H5VL_iod_server_attr_exists_cb(AXE_engine_t UNUSED axe_engine, /* Open the object where the attribute needs to be checked. */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); if(loc_id != obj_id || IOD_OBJ_INVALID == input->loc_attrkv_id) { /* get scratch pad of the parent */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* if attribute KV does not exist, return false*/ @@ -837,12 +837,12 @@ H5VL_iod_server_attr_exists_cb(AXE_engine_t UNUSED axe_engine, /* open the attribute KV in scratch pad */ if (iod_obj_open_read(coh, sp[1], rtid, NULL, &attr_kv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } else { /* open the attribute KV */ if (iod_obj_open_read(coh, input->loc_attrkv_id, rtid, NULL, &attr_kv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } /* close parent group if it is not the location we started the @@ -924,35 +924,35 @@ H5VL_iod_server_attr_rename_cb(AXE_engine_t UNUSED axe_engine, /* Open the object where the attribute needs to be checked. */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); if(loc_id != obj_id || IOD_OBJ_INVALID == input->loc_attrkv_id) { /* get scratch pad of the parent */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* if attribute KV does not exist, return error*/ if(IOD_OBJ_INVALID == sp[1]) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "Object has no attributes"); + HGOTO_ERROR_FF(FAIL, "Object has no attributes"); /* open the attribute KV in scratch pad */ if (iod_obj_open_read(coh, sp[1], wtid, NULL /*hints*/, &attr_kv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, sp[1], wtid, NULL /*hints*/, &attr_kv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } else { /* open the attribute KV */ if (iod_obj_open_read(coh, input->loc_attrkv_id, wtid, NULL /*hints*/, &attr_kv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, input->loc_attrkv_id, wtid, NULL /*hints*/, &attr_kv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } /* close parent group if it is not the location we started the @@ -964,7 +964,7 @@ H5VL_iod_server_attr_rename_cb(AXE_engine_t UNUSED axe_engine, /* get attribute ID */ if(H5VL_iod_get_metadata(attr_kv_oh.rd_oh, rtid, H5VL_IOD_LINK, old_name, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve Attribute ID from parent KV store"); + HGOTO_ERROR_FF(FAIL, "can't retrieve Attribute ID from parent KV store"); HDassert(iod_link.link_type == H5L_TYPE_HARD); attr_id = iod_link.u.iod_id; @@ -976,18 +976,18 @@ H5VL_iod_server_attr_rename_cb(AXE_engine_t UNUSED axe_engine, kvs.cs = NULL; kvs.ret = &ret; if(iod_kv_unlink_keys(attr_kv_oh.wr_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); /* insert attribute with new name */ if(H5VL_iod_insert_new_link(attr_kv_oh.wr_oh, wtid, new_name, H5L_TYPE_HARD, &attr_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close the Attribute KV object */ if(iod_obj_close(attr_kv_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTFREE, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(iod_obj_close(attr_kv_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTFREE, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); done: @@ -1053,35 +1053,35 @@ H5VL_iod_server_attr_remove_cb(AXE_engine_t UNUSED axe_engine, /* Open the object where the attribute needs to be removed. */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); if(loc_id != obj_id) { /* get scratch pad of the parent */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* if attribute KV does not exist, return error*/ if(IOD_OBJ_INVALID == sp[1]) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "Object has no attributes"); + HGOTO_ERROR_FF(FAIL, "Object has no attributes"); /* open the attribute KV in scratch pad */ if (iod_obj_open_read(coh, sp[1], wtid, NULL /*hints*/, &attr_kv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, sp[1], wtid, NULL /*hints*/, &attr_kv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } else { /* open the attribute KV */ if (iod_obj_open_read(coh, input->loc_attrkv_id, wtid, NULL /*hints*/, &attr_kv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, input->loc_attrkv_id, wtid, NULL /*hints*/, &attr_kv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } step ++; @@ -1089,7 +1089,7 @@ H5VL_iod_server_attr_remove_cb(AXE_engine_t UNUSED axe_engine, /* get attribute ID */ if(H5VL_iod_get_metadata(attr_kv_oh.rd_oh, rtid, H5VL_IOD_LINK, attr_name, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve Attribute ID from parent KV store"); + HGOTO_ERROR_FF(FAIL, "can't retrieve Attribute ID from parent KV store"); HDassert(iod_link.link_type == H5L_TYPE_HARD); attr_id = iod_link.u.iod_id; @@ -1097,13 +1097,13 @@ H5VL_iod_server_attr_remove_cb(AXE_engine_t UNUSED axe_engine, /* remove metadata KV of attribute */ /* open the attribute */ if (iod_obj_open_read(coh, attr_id, wtid, NULL /*hints*/, &attr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); step ++; /* get scratch pad of the attribute */ if(iod_obj_get_scratch(attr_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); /* close the attribute oh */ iod_obj_close(attr_oh, NULL, NULL); @@ -1113,13 +1113,13 @@ H5VL_iod_server_attr_remove_cb(AXE_engine_t UNUSED axe_engine, if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } ret = iod_obj_unlink(coh, sp[0], wtid, NULL); if(ret < 0) { fprintf(stderr, "ret %d error %s\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink MDKV of attribute object"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink MDKV of attribute object"); } /* remove attribute */ @@ -1129,7 +1129,7 @@ H5VL_iod_server_attr_remove_cb(AXE_engine_t UNUSED axe_engine, kvs.cs = NULL; kvs.ret = &ret; if(iod_kv_unlink_keys(attr_kv_oh.wr_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); /* close the Attribute KV object */ iod_obj_close(attr_kv_oh.rd_oh, NULL, NULL); @@ -1140,7 +1140,7 @@ H5VL_iod_server_attr_remove_cb(AXE_engine_t UNUSED axe_engine, ret = iod_obj_unlink(coh, attr_id, wtid, NULL); if(ret != 0) { fprintf(stderr, "ret %d error %s\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink object"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink object"); } done: @@ -1205,9 +1205,9 @@ H5VL_iod_server_attr_close_cb(AXE_engine_t UNUSED axe_engine, #endif if((iod_obj_close(iod_oh.rd_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if((iod_obj_close(iod_oh.wr_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); done: #if H5_EFF_DEBUG diff --git a/src/H5VLiod_dset.c b/src/H5VLiod_dset.c index 12cd76d..2650570 100644 --- a/src/H5VLiod_dset.c +++ b/src/H5VLiod_dset.c @@ -157,7 +157,7 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, /* get the scope for data integrity checks for raw data */ if(H5Pget_ocpl_enable_checksum(dcpl_id, &enable_checksum) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); if(name) { /* the traversal will retrieve the location where the dataset needs @@ -165,7 +165,7 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, does not exist. */ if(H5VL_iod_server_traverse(coh, loc_id, loc_handle, name, wtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); } else { /* this is an anon dataset.. no link information */ @@ -209,7 +209,7 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, } else { if(H5Sget_simple_extent_dims(space_id, current_dims, array_dims) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get dimentions' sizes"); + HGOTO_ERROR_FF(FAIL, "can't get dimentions' sizes"); if(H5S_UNLIMITED == array_dims[0]) { array_dims[0] = current_dims[0]; @@ -235,23 +235,23 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, &array, &dset_id, NULL); if(ret != 0) { fprintf(stderr, "ret: %d error: %s\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create Array object"); + HGOTO_ERROR_FF(FAIL, "can't create Array object"); } if (iod_obj_open_write(coh, dset_id, wtid, NULL, &dset_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open Dataset for Write"); + HGOTO_ERROR_FF(FAIL, "can't open Dataset for Write"); if (iod_obj_open_read(coh, dset_id, wtid, NULL, &dset_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open Dataset for Read"); + HGOTO_ERROR_FF(FAIL, "can't open Dataset for Read"); step ++; /* create the attribute KV object for the dataset */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &attrkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create attribute KV object"); + HGOTO_ERROR_FF(FAIL, "can't create attribute KV object"); /* create the metadata KV object for the dataset */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &mdkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* set values for the scratch pad object */ sp[0] = mdkv_id; @@ -266,33 +266,33 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, sp_cs = H5_checksum_crc64(&sp, sizeof(sp)); if (iod_obj_set_scratch(dset_oh.wr_oh, wtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } else { if (iod_obj_set_scratch(dset_oh.wr_oh, wtid, &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } /* Open Metadata KV object for write */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't create scratch pad"); step ++; /* insert plist metadata */ if(H5VL_iod_insert_plist(mdkv_oh, wtid, dcpl_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh, wtid, (uint64_t)1, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert object type metadata */ if(H5VL_iod_insert_object_type(mdkv_oh, wtid, H5I_DATASET, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* MSC - need to check size of datatype if it fits in entry otherwise create a BLOB*/ @@ -300,16 +300,16 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, /* insert datatype metadata */ if(H5VL_iod_insert_datatype(mdkv_oh, wtid, input->type_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert dataspace metadata */ if(H5VL_iod_insert_dataspace(mdkv_oh, wtid, space_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close the Metadata KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); step --; @@ -317,7 +317,7 @@ H5VL_iod_server_dset_create_cb(AXE_engine_t UNUSED axe_engine, if(name) { if(H5VL_iod_insert_new_link(cur_oh.wr_oh, wtid, last_comp, H5L_TYPE_HARD, &dset_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); } output.iod_oh.rd_oh.cookie = dset_oh.rd_oh.cookie; @@ -413,43 +413,43 @@ H5VL_iod_server_dset_open_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open dset */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, name, rtid, cs_scope, &dset_id, &dset_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* open a write handle on the ID. */ if (iod_obj_open_write(coh, dset_id, rtid, NULL, &dset_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current dset"); + HGOTO_ERROR_FF(FAIL, "can't open current dset"); step ++; /* get scratch pad of the dataset */ if(iod_obj_get_scratch(dset_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); step ++; if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.dcpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, cs_scope, NULL, &output.type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &output.space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); step --; output.iod_id = dset_id; @@ -539,7 +539,7 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, /* open the dataset if we don't have the handle yet */ if(iod_oh.rd_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, iod_id, rtid, NULL /*hints*/, &iod_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } @@ -553,14 +553,14 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, /* get the scope for data integrity checks for raw data */ if(H5Pget_rawdata_integrity_scope(dxpl_id, &raw_cs_scope) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); /* retrieve size of bulk data asked for to be read */ size = HG_Bulk_handle_get_size(bulk_handle); /* allocate buffer to hold data */ if(NULL == (buf = malloc(size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* get the number of points selected */ nelmts = (size_t)H5Sget_select_npoints(space_id); @@ -581,7 +581,7 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, /* get replica ID from dxpl */ if(H5Pget_read_replica(dxpl_id, &read_tid) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get replica ID from dxpl"); + HGOTO_ERROR_FF(FAIL, "can't get replica ID from dxpl"); if(read_tid) { fprintf(stderr, "Reading from replica tag %"PRIx64"\n", read_tid); @@ -604,7 +604,7 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, /* do data conversion */ if(H5Tconvert(src_id, dst_id, nelmts, buf, NULL, dxpl_id) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); if(raw_cs_scope) { /* calculate a checksum for the data to be sent */ @@ -617,7 +617,7 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, #endif /* MSC - check if client requested to corrupt data */ if(H5Pget_dxpl_inject_corruption(dxpl_id, &flag) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read property list"); + HGOTO_ERROR_FF(FAIL, "can't read property list"); if(flag) { fprintf(stderr, "Injecting a bad data value to cause corruption \n"); ((char *)buf)[0] = 54; @@ -628,7 +628,7 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, /* If the data is of variable length, special access is required */ if(H5VL__iod_server_vl_data_read(coh, axe_engine, input->axe_id, nelmts, buf, dxpl_id, rtid) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); } /* Create a new block handle to write the data */ @@ -636,14 +636,14 @@ H5VL_iod_server_dset_read_cb(AXE_engine_t axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(dest, bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* free block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); #if H5_EFF_DEBUG fprintf(stderr, "Done with dset read, checksum %016lX, sending response to client\n", cs); @@ -658,7 +658,7 @@ done: fprintf(stderr, "FAILED dset read, checksum %016lX \n", cs); if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &output)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); input = (dset_io_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -671,7 +671,7 @@ done: /* close the dataset if we opened it in this routine */ if(TRUE == opened_locally) { if(iod_obj_close(iod_oh.rd_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_dset_read_cb() */ @@ -720,7 +720,7 @@ H5VL_iod_server_dset_get_vl_size_cb(AXE_engine_t UNUSED axe_engine, /* open the dataset if we don't have the handle yet */ if(iod_oh.rd_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_write(coh, iod_id, rtid, NULL /*hints*/, &iod_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } @@ -730,7 +730,7 @@ H5VL_iod_server_dset_get_vl_size_cb(AXE_engine_t UNUSED axe_engine, /* allocate buffer to hold blob IDs */ if(NULL == (buf = malloc(nelmts * elmt_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* buffer always contains the length of each sequence, so initialize it to the size required to store those lengths */ @@ -739,7 +739,7 @@ H5VL_iod_server_dset_get_vl_size_cb(AXE_engine_t UNUSED axe_engine, /* read the array values containing the BLOB IDs and lengths */ if(H5VL__iod_server_final_io(iod_oh.rd_oh, space_id, elmt_size, FALSE, buf, buf_size, (uint64_t)0, cs_scope, rtid) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* MSC - create a bulk block handle. Mercury does not support segmented handles yet, so we need a temporrary buffer. */ @@ -751,14 +751,14 @@ H5VL_iod_server_dset_get_vl_size_cb(AXE_engine_t UNUSED axe_engine, H5VL_iod_type_info_t type_info; if(NULL == (temp_buf = (size_t *)malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate size buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate size buffer"); buf_ptr = (uint8_t *)buf; temp_ptr = (uint8_t *)temp_buf; /* Get type info */ if(H5VL_iod_get_type_info(type_id, &type_info) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to get datatype info"); + HGOTO_ERROR_FF(FAIL, "failed to get datatype info"); assert(1 == type_info.num_vls); @@ -791,15 +791,15 @@ H5VL_iod_server_dset_get_vl_size_cb(AXE_engine_t UNUSED axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(dest, bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* free block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); if(temp_buf) { free(temp_buf); @@ -816,7 +816,7 @@ done: output.buf_size = buf_size; if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &output)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); #if H5_EFF_DEBUG fprintf(stderr, "Done with dset get vl size (%zu), sending response to client\n", buf_size); @@ -827,7 +827,7 @@ done: /* close the dataset if we opened it in this routine */ if(TRUE == opened_locally) { if(iod_obj_close(iod_oh.rd_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_dset_get_vl_size_cb() */ @@ -883,7 +883,7 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, /* open the dataset if we don't have the handle yet */ if(iod_oh.wr_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_write(coh, iod_id, wtid, NULL /*hints*/, &iod_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open dataset for write"); + HGOTO_ERROR_FF(FAIL, "can't open dataset for write"); opened_locally = TRUE; } @@ -899,7 +899,7 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, /* Get type info */ if(H5VL_iod_get_type_info(src_id, &type_info) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to get datatype info"); + HGOTO_ERROR_FF(FAIL, "failed to get datatype info"); if(type_info.vls) { hg_bulk_segment_t *segments = NULL; @@ -913,42 +913,42 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, /* Get size of vl_lengths array and allocate local buffer */ vl_lengths_size = HG_Bulk_handle_get_size(vl_len_bulk_handle); if(vl_lengths_size == 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "no vlen lengths sent"); + HGOTO_ERROR_FF(FAIL, "no vlen lengths sent"); if(NULL == (vl_lengths = (char *)malloc(vl_lengths_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate vlen lengths buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate vlen lengths buffer"); /* Register local memory buffer */ if(HG_SUCCESS != HG_Bulk_handle_create(vl_lengths, vl_lengths_size, HG_BULK_READWRITE, &vl_len_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "create vlen bulk handle"); + HGOTO_ERROR_FF(FAIL, "create vlen bulk handle"); /* Receive vl length data from client */ if(HG_SUCCESS != HG_Bulk_read_all(source, vl_len_bulk_handle, vl_len_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't read vlen lengths bulk data"); + HGOTO_ERROR_FF(FAIL, "can't read vlen lengths bulk data"); /* Wait for bulk data read to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't wait for vlen lengths bulk data operation"); + HGOTO_ERROR_FF(FAIL, "can't wait for vlen lengths bulk data operation"); /* Free the bulk handle */ if(HG_SUCCESS != HG_Bulk_handle_free(vl_len_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free vlen bulk handle"); + HGOTO_ERROR_FF(FAIL, "can't free vlen bulk handle"); if(NULL == (buf = malloc(nelmts * type_info.size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate data buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate data buffer"); /* Create segments from vl lengths */ if(H5VL_iod_create_segments_recv((char *)buf, &type_info, nelmts, &segments, &num_segments, vl_lengths, vl_lengths_size, &free_list, &free_list_len) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create segments for bulk data transfer"); + HGOTO_ERROR_FF(FAIL, "can't create segments for bulk data transfer"); assert(segments); #if 1 if(H5VL__iod_server_vl_data_write(coh, iod_id, iod_oh, space_id, src_id, dst_id, type_info, nelmts, num_segments, segments, dxpl_id, wtid, rtid, source, bulk_handle, raw_cs_scope) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't write VL data to array object"); + HGOTO_ERROR_FF(FAIL, "can't write VL data to array object"); #else { @@ -968,19 +968,19 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, /* Register non-contiguous memory segments */ if(HG_SUCCESS != HG_Bulk_handle_create_segments(segments, num_segments, HG_BULK_READWRITE, &vl_data_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create Bulk Data Handle"); + HGOTO_ERROR_FF(FAIL, "can't create Bulk Data Handle"); /* Receive bulk data from client */ if(HG_SUCCESS != HG_Bulk_read_all(source, bulk_handle, vl_data_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't read bulk data"); + HGOTO_ERROR_FF(FAIL, "can't read bulk data"); /* Wait for bulk data read to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't wait for bulk data operation"); + HGOTO_ERROR_FF(FAIL, "can't wait for bulk data operation"); /* Free the bulk handle */ if(HG_SUCCESS != HG_Bulk_handle_free(vl_data_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free bulk handle"); + HGOTO_ERROR_FF(FAIL, "can't free bulk handle"); { hvl_t *buf_ptr = (hvl_t *)buf; @@ -1026,33 +1026,33 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, /* allocate buffer to hold data */ if(NULL == (buf = malloc(size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* create a Mercury block handle for transfer */ HG_Bulk_handle_create(buf, size, HG_BULK_READWRITE, &bulk_block_handle); /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_read_all(source, bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* free the bds block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); /* MSC - check if client requested to corrupt data */ if(H5Pget_dxpl_inject_corruption(dxpl_id, &flag) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read property list"); + HGOTO_ERROR_FF(FAIL, "can't read property list"); if(flag) { ((int *)buf)[0] = 10; } /* get the scope for data integrity checks for raw data */ if(H5Pget_rawdata_integrity_scope(dxpl_id, &raw_cs_scope) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); /* verify data if transfer flag is set */ if(raw_cs_scope & H5_CHECKSUM_TRANSFER) { @@ -1085,7 +1085,7 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, /* convert data if needed */ if(H5Tconvert(src_id, dst_id, nelmts, buf, NULL, dxpl_id) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed") + HGOTO_ERROR_FF(FAIL, "data type conversion failed") #if 0 { @@ -1101,7 +1101,7 @@ H5VL_iod_server_dset_write_cb(AXE_engine_t UNUSED axe_engine, elmt_size = H5Tget_size(dst_id); if(H5VL__iod_server_final_io(iod_oh.wr_oh, space_id, elmt_size, TRUE, buf, buf_size, cs, raw_cs_scope, wtid) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't write to array object"); + HGOTO_ERROR_FF(FAIL, "can't write to array object"); } #if H5_EFF_DEBUG @@ -1116,7 +1116,7 @@ done: #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); input = (dset_io_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -1130,7 +1130,7 @@ done: /* close the dataset if we opened it in this routine */ if(TRUE == opened_locally) { if(iod_obj_close(iod_oh.wr_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_dset_write_cb() */ @@ -1175,13 +1175,13 @@ H5VL_iod_server_dset_set_extent_cb(AXE_engine_t UNUSED axe_engine, /* open the dataset if we don't have the handle yet */ if(iod_oh.wr_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_write(coh, iod_id, wtid, NULL /*hints*/, &iod_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } /* extend along the first dimension only */ if(iod_array_extend(iod_oh.wr_oh, wtid, (iod_size_t)input->dims.size[0], NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't extend dataset"); + HGOTO_ERROR_FF(FAIL, "can't extend dataset"); /* modify the dataspace of the dataset */ { @@ -1192,28 +1192,28 @@ H5VL_iod_server_dset_set_extent_cb(AXE_engine_t UNUSED axe_engine, /* open the metadata scratch pad */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); /* get the stored dataset dataspace */ if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); if((rank = H5Sget_simple_extent_dims(space_id, current_dims, array_dims)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get dimentions' sizes"); + HGOTO_ERROR_FF(FAIL, "can't get dimentions' sizes"); /* Modify the size of the data space */ if(H5Sset_extent_simple(space_id, rank, input->dims.size, array_dims) < 0) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to modify size of data space"); + HGOTO_ERROR_FF(FAIL, "unable to modify size of data space"); /* insert dataspace metadata */ if(H5VL_iod_insert_dataspace(mdkv_oh, wtid, space_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } done: @@ -1229,7 +1229,7 @@ done: /* close the dataset if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_dset_set_extent_cb() */ @@ -1266,9 +1266,9 @@ H5VL_iod_server_dset_close_cb(AXE_engine_t UNUSED axe_engine, #endif if(iod_obj_close(iod_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Read Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Read Array object"); if(iod_obj_close(iod_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Write Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Write Array object"); done: #if H5_EFF_DEBUG @@ -1316,14 +1316,14 @@ H5VL__iod_server_final_io(iod_handle_t iod_oh, hid_t space_id, size_t elmt_size, /* get the rank of the dataspace */ if((ndims = H5Sget_simple_extent_ndims(space_id)) < 0) - HGOTO_ERROR2(H5E_INTERNAL, H5E_CANTGET, FAIL, "unable to get dataspace dimesnsion"); + HGOTO_ERROR_FF(FAIL, "unable to get dataspace dimesnsion"); /* handle scalar dataspace */ if(0 == ndims) { ndims = 1; /* allocate the IOD hyperslab descriptors needed */ if(NULL == (hslabs = (iod_hyperslab_t *)malloc(sizeof(iod_hyperslab_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate iod array descriptors"); + HGOTO_ERROR_FF(FAIL, "can't allocate iod array descriptors"); hslabs[0].start = (iod_size_t *)malloc(sizeof(iod_size_t)); hslabs[0].stride = (iod_size_t *)malloc(sizeof(iod_size_t)); @@ -1340,12 +1340,12 @@ H5VL__iod_server_final_io(iod_handle_t iod_oh, hid_t space_id, size_t elmt_size, /* get the number of decriptors required, i.e. the numbers of iod I/O operations needed */ if(H5VL_iod_get_file_desc(space_id, &num_descriptors, NULL) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTGET, FAIL, "unable to generate IOD file descriptor from dataspace selection"); + HGOTO_ERROR_FF(FAIL, "unable to generate IOD file descriptor from dataspace selection"); /* allocate the IOD hyperslab descriptors needed */ if(NULL == (hslabs = (iod_hyperslab_t *)malloc (sizeof(iod_hyperslab_t) * (size_t)num_descriptors))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate iod array descriptors"); + HGOTO_ERROR_FF(FAIL, "can't allocate iod array descriptors"); for(n=0 ; n<num_descriptors ; n++) { hslabs[n].start = (iod_size_t *)malloc(sizeof(iod_size_t) * (size_t)ndims); @@ -1356,7 +1356,7 @@ H5VL__iod_server_final_io(iod_handle_t iod_oh, hid_t space_id, size_t elmt_size, /* generate the descriptors after allocating the array */ if(H5VL_iod_get_file_desc(space_id, &num_descriptors, hslabs) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTGET, FAIL, "unable to generate IOD file descriptor from dataspace selection"); + HGOTO_ERROR_FF(FAIL, "unable to generate IOD file descriptor from dataspace selection"); } file_desc = (iod_array_iodesc_t *)hslabs; @@ -1366,7 +1366,7 @@ H5VL__iod_server_final_io(iod_handle_t iod_oh, hid_t space_id, size_t elmt_size, /* allocate cs array */ if(NULL == (cs_list = (iod_checksum_t *)calloc (sizeof(iod_checksum_t), (size_t)num_descriptors))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate checksum array"); + HGOTO_ERROR_FF(FAIL, "can't allocate checksum array"); } #if H5_EFF_DEBUG else { @@ -1408,7 +1408,7 @@ H5VL__iod_server_final_io(iod_handle_t iod_oh, hid_t space_id, size_t elmt_size, ret = iod_array_write(iod_oh, tid, NULL, mem_desc, file_desc, cs_list, NULL); if(ret != 0) { fprintf(stderr, "ret: %d error: %s\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't write to array object"); + HGOTO_ERROR_FF(FAIL, "can't write to array object"); } } else { @@ -1416,7 +1416,7 @@ H5VL__iod_server_final_io(iod_handle_t iod_oh, hid_t space_id, size_t elmt_size, ret = iod_array_read(iod_oh, tid, NULL, mem_desc, file_desc, cs_list, NULL); if(ret != 0) { fprintf(stderr, "ret: %d error: %s\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); } } @@ -1513,7 +1513,7 @@ H5VL__iod_server_vl_data_read(iod_handle_t coh, AXE_engine_t axe_engine, AXE_tas /* retrieve the buffer that contains the blob IDs and their sizes that was created in the get_size operation */ if(AXE_SUCCEED != AXEget_op_data(axe_engine, axe_id, &get_size_op_data)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to get farm op_data"); + HGOTO_ERROR_FF(FAIL, "failed to get farm op_data"); op_data = (op_data_t *)get_size_op_data; vlen_buf = op_data->output; @@ -1521,19 +1521,19 @@ H5VL__iod_server_vl_data_read(iod_handle_t coh, AXE_engine_t axe_engine, AXE_tas /* allocate a blob list to read the data */ if(NULL == (io_blob = (iod_blob_io_t *)malloc(sizeof(iod_blob_io_t) * nelmts))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate blob io array"); + HGOTO_ERROR_FF(FAIL, "can't allocate blob io array"); /* allocate an array for the blob OHs */ if(NULL == (blob_oh = (iod_handle_t *)malloc(sizeof(iod_handle_t) * nelmts))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate blob io array"); + HGOTO_ERROR_FF(FAIL, "can't allocate blob io array"); /* allocate cs array */ if(NULL == (cs_list = (iod_checksum_t *)calloc(sizeof(iod_checksum_t), nelmts))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate checksum array"); + HGOTO_ERROR_FF(FAIL, "can't allocate checksum array"); /* allocate return array */ if(NULL == (ret_list = (iod_ret_t *)calloc(sizeof(iod_ret_t), nelmts))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate return array"); + HGOTO_ERROR_FF(FAIL, "can't allocate return array"); elmt_size = sizeof(iod_obj_id_t) + sizeof(iod_size_t); @@ -1553,7 +1553,7 @@ H5VL__iod_server_vl_data_read(iod_handle_t coh, AXE_engine_t axe_engine, AXE_tas #endif if(iod_obj_open_read(coh, blob_id, rtid, NULL, &blob_oh[u], NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open BLOB for Read"); + HGOTO_ERROR_FF(FAIL, "can't open BLOB for Read"); /* create memory descriptor for reading */ mem_desc = (iod_mem_desc_t *)malloc(sizeof(iod_mem_desc_t) + sizeof(iod_mem_frag_t)); @@ -1581,17 +1581,17 @@ H5VL__iod_server_vl_data_read(iod_handle_t coh, AXE_engine_t axe_engine, AXE_tas /* Read list IO */ if(iod_blob_read_list(coh, rtid, (int)nelmts, io_blob, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from blob objects"); + HGOTO_ERROR_FF(FAIL, "can't read from blob objects"); for(u=0 ; u<nelmts; u++) { if(ret_list[u] < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); free(io_blob[u].mem_desc); free(io_blob[u].io_desc); if(iod_obj_close(blob_oh[u], NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } done: @@ -1661,23 +1661,23 @@ H5VL__iod_server_vl_data_write(iod_handle_t coh, iod_obj_id_t iod_id, iod_handle } /* end for */ if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate data buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate data buffer"); /* Register local memory buffer */ if(HG_SUCCESS != HG_Bulk_handle_create(buf, buf_size, HG_BULK_READWRITE, &vl_data_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "create vlen bulk handle"); + HGOTO_ERROR_FF(FAIL, "create vlen bulk handle"); /* Receive vl length data from client */ if(HG_SUCCESS != HG_Bulk_read_all(source, bulk_handle, vl_data_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't read vlen lengths bulk data"); + HGOTO_ERROR_FF(FAIL, "can't read vlen lengths bulk data"); /* Wait for bulk data read to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't wait for vlen lengths bulk data operation"); + HGOTO_ERROR_FF(FAIL, "can't wait for vlen lengths bulk data operation"); /* Free the bulk handle */ if(HG_SUCCESS != HG_Bulk_handle_free(vl_data_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free vlen bulk handle"); + HGOTO_ERROR_FF(FAIL, "can't free vlen bulk handle"); /* set other parameters needed to do IO */ udata.coh = coh; @@ -1694,7 +1694,7 @@ H5VL__iod_server_vl_data_write(iod_handle_t coh, iod_obj_id_t iod_id, iod_handle /* iterate over every element and read/write it as a BLOB object */ if(H5Diterate(&bogus, mem_type_id, space_id, H5VL__iod_server_vl_data_write_cb, &udata) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to compute buffer size"); + HGOTO_ERROR_FF(FAIL, "failed to compute buffer size"); done: if(buf) { @@ -1781,11 +1781,11 @@ H5VL__iod_server_vl_data_write_cb(void UNUSED *elem, hid_t type_id, unsigned ndi ret = iod_obj_open_write(coh, blob_id, wtid, NULL, &blob_oh, NULL); if(ret != 0) { fprintf(stderr, "ret: %d error: %s %"PRIx64"\n", ret, strerror(-ret), blob_id); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Failed to open BLOB object"); + HGOTO_ERROR_FF(FAIL, "Failed to open BLOB object"); } } else - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Failed to create BLOB object"); + HGOTO_ERROR_FF(FAIL, "Failed to create BLOB object"); } buf_size = udata->segments[udata->cur_seg].size; @@ -1807,7 +1807,7 @@ H5VL__iod_server_vl_data_write_cb(void UNUSED *elem, hid_t type_id, unsigned ndi /* write the VL data to the blob */ if(iod_blob_write(blob_oh, wtid, NULL, mem_desc, blob_desc, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to write BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to write BLOB object"); free(mem_desc); mem_desc = NULL; @@ -1816,7 +1816,7 @@ H5VL__iod_server_vl_data_write_cb(void UNUSED *elem, hid_t type_id, unsigned ndi /* close BLOB */ if(iod_obj_close(blob_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(created) { /* update the array element with the blob_id and sequence length */ @@ -1846,7 +1846,7 @@ H5VL__iod_server_vl_data_write_cb(void UNUSED *elem, hid_t type_id, unsigned ndi /* write the blob ID & size to the array element */ if(iod_array_write(iod_oh.wr_oh, wtid, NULL, mem_desc, &file_desc, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); free(mem_desc); mem_desc = NULL; diff --git a/src/H5VLiod_dtype.c b/src/H5VLiod_dtype.c index 64b834c..ce9315a 100644 --- a/src/H5VLiod_dtype.c +++ b/src/H5VLiod_dtype.c @@ -82,7 +82,7 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, /* get the scope for data integrity checks for raw data */ if(H5Pget_ocpl_enable_checksum(tcpl_id, &enable_checksum) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); if((cs_scope & H5_CHECKSUM_IOD) && enable_checksum) { obj_create_hint = (iod_hint_list_t *)malloc(sizeof(iod_hint_list_t) + sizeof(iod_hint_t)); @@ -95,7 +95,7 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, does not exist. */ if(H5VL_iod_server_traverse(coh, loc_id, loc_handle, name, wtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); #if H5_EFF_DEBUG fprintf(stderr, "Creating Datatype ID %"PRIx64" (CV %"PRIu64", TR %"PRIu64") ", @@ -110,24 +110,24 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, /* create the datatype */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_BLOB, NULL, NULL, &dtype_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create BLOB"); + HGOTO_ERROR_FF(FAIL, "can't create BLOB"); if (iod_obj_open_read(coh, dtype_id, wtid, NULL, &dtype_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open BLOB"); + HGOTO_ERROR_FF(FAIL, "can't open BLOB"); if (iod_obj_open_write(coh, dtype_id, wtid, NULL, &dtype_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open BLOB"); + HGOTO_ERROR_FF(FAIL, "can't open BLOB"); step ++; /* create the metadata KV object for the datatype */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &mdkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* create the attribute KV object for the datatype */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &attr_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create attribute KV object"); + HGOTO_ERROR_FF(FAIL, "can't create attribute KV object"); /* set values for the scratch pad object */ sp[0] = mdkv_id; @@ -141,27 +141,27 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, sp_cs = H5_checksum_crc64(&sp, sizeof(sp)); if (iod_obj_set_scratch(dtype_oh.wr_oh, wtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } else { if (iod_obj_set_scratch(dtype_oh.wr_oh, wtid, &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } /* Store Metadata in scratch pad */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't open metadata KV object"); step ++; /* determine the buffer size needed to store the encoded type of the datatype */ if(H5Tencode(input->type_id, NULL, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode datatype type"); + HGOTO_ERROR_FF(FAIL, "failed to encode datatype type"); if(NULL == (buf = malloc (buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate type buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate type buffer"); /* encode datatype of the datatype */ if(H5Tencode(input->type_id, buf, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode datatype type"); + HGOTO_ERROR_FF(FAIL, "failed to encode datatype type"); /* create memory descriptor for writing */ mem_desc = (iod_mem_desc_t *)malloc(sizeof(iod_mem_desc_t) + sizeof(iod_mem_frag_t)); @@ -186,12 +186,12 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, /* write the serialized type value to the BLOB object */ if(iod_blob_write(dtype_oh.wr_oh, wtid, NULL, mem_desc, file_desc, &dt_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to write BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to write BLOB object"); } else { /* write the serialized type value to the BLOB object */ if(iod_blob_write(dtype_oh.wr_oh, wtid, NULL, mem_desc, file_desc, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to write BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to write BLOB object"); } free(mem_desc); @@ -199,15 +199,15 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, /* insert plist metadata */ if(H5VL_iod_insert_plist(mdkv_oh, wtid, tcpl_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh, wtid, (uint64_t)1, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert object type metadata */ if(H5VL_iod_insert_object_type(mdkv_oh, wtid, H5I_DATATYPE, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* store the datatype size */ { @@ -224,25 +224,25 @@ H5VL_iod_server_dtype_commit_cb(AXE_engine_t UNUSED axe_engine, cs[0] = H5_checksum_crc64(kv.key, kv.key_len); cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } } /* close the Metadata KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); step --; /* add link in parent group to current object */ if(H5VL_iod_insert_new_link(cur_oh.wr_oh, wtid, last_comp, H5L_TYPE_HARD, &dtype_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); output.iod_oh.rd_oh.cookie = dtype_oh.rd_oh.cookie; output.iod_oh.wr_oh.cookie = dtype_oh.wr_oh.cookie; @@ -342,31 +342,31 @@ H5VL_iod_server_dtype_open_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open dtype */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, name, rtid, cs_scope, &dtype_id, &dtype_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* open a write handle on the ID. */ if (iod_obj_open_write(coh, dtype_id, rtid, NULL, &dtype_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current datatype"); + HGOTO_ERROR_FF(FAIL, "can't open current datatype"); step ++; /* get scratch pad of the datatype */ if(iod_obj_get_scratch(dtype_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); step ++; if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.tcpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve tcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve tcpl"); val_size = sizeof(iod_size_t); key_size = strlen(H5VL_IOD_KEY_DTYPE_SIZE); @@ -374,20 +374,20 @@ H5VL_iod_server_dtype_open_cb(AXE_engine_t UNUSED axe_engine, /* retrieve blob size metadata from scratch pad */ if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "datatype size lookup failed"); + HGOTO_ERROR_FF(FAIL, "datatype size lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate BLOB read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate BLOB read buffer"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); step --; /* create memory descriptor for writing */ @@ -405,7 +405,7 @@ H5VL_iod_server_dtype_open_cb(AXE_engine_t UNUSED axe_engine, /* read the serialized type value from the BLOB object */ if(iod_blob_read(dtype_oh.rd_oh, rtid, NULL, mem_desc, file_desc, &blob_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to read from BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to read from BLOB object"); if(blob_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* calculate a checksum for the datatype */ @@ -417,12 +417,12 @@ H5VL_iod_server_dtype_open_cb(AXE_engine_t UNUSED axe_engine, #endif /* Verifty checksum against one given by IOD */ if(blob_cs != dt_cs) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "Data Corruption detected when reading datatype"); + HGOTO_ERROR_FF(FAIL, "Data Corruption detected when reading datatype"); } /* decode the datatype */ if((output.type_id = H5Tdecode(buf)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to decode datatype"); + HGOTO_ERROR_FF(FAIL, "unable to decode datatype"); free(mem_desc); free(file_desc); @@ -497,13 +497,13 @@ H5VL_iod_server_dtype_close_cb(AXE_engine_t UNUSED axe_engine, if(IOD_OH_UNDEFINED == iod_oh.wr_oh.cookie || IOD_OH_UNDEFINED == iod_oh.rd_oh.cookie) { - HGOTO_ERROR2(H5E_SYM, H5E_CANTCLOSEOBJ, FAIL, "can't close object with invalid handle"); + HGOTO_ERROR_FF(FAIL, "can't close object with invalid handle"); } if((iod_obj_close(iod_oh.rd_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Read OH"); + HGOTO_ERROR_FF(FAIL, "can't close Read OH"); if((iod_obj_close(iod_oh.wr_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Write OH"); + HGOTO_ERROR_FF(FAIL, "can't close Write OH"); #if H5_EFF_DEBUG fprintf(stderr, "Done with dtype close, sending response to client\n"); diff --git a/src/H5VLiod_file.c b/src/H5VLiod_file.c index c4ec231..09e2094 100644 --- a/src/H5VLiod_file.c +++ b/src/H5VLiod_file.c @@ -82,10 +82,10 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, fcpl_id = input->fcpl_id; if(H5Pget_metadata_integrity_scope(input->fapl_id, &cs_scope) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); if(H5Pget_ocpl_enable_checksum(fcpl_id, &enable_checksum) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); /* scratch pad integrity in the container */ if(cs_scope & H5_CHECKSUM_IOD) { @@ -104,24 +104,24 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, /* Create the Container */ ret = iod_container_open(input->name, con_open_hint, mode, &coh, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create container"); + HGOTO_ERROR_FF(FAIL, "can't create container"); /* MSC - skip transaction 0 since it can't be persisted */ ret = iod_trans_start(coh, &first_tid, NULL, num_peers, IOD_TRANS_W, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't start transaction 0"); + HGOTO_ERROR_FF(FAIL, "can't start transaction 0"); /* Finish the transaction */ ret = iod_trans_finish(coh, first_tid, NULL, 0, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't finish transaction 0"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction 0"); first_tid = 1; /* Take transaction 1 to create root group */ ret = iod_trans_start(coh, &first_tid, NULL, num_peers, IOD_TRANS_W, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't start transaction 1"); + HGOTO_ERROR_FF(FAIL, "can't start transaction 1"); /* create the root group */ root_ret = iod_obj_create(coh, first_tid, obj_create_hint, IOD_OBJ_KV, @@ -130,13 +130,13 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, /* root group has been created, open it */ ret = iod_obj_open_write(coh, root_id, first_tid, NULL, &root_oh.wr_oh, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open root group for write"); + HGOTO_ERROR_FF(FAIL, "can't open root group for write"); ret = iod_obj_open_read(coh, root_id, first_tid, NULL, &root_oh.rd_oh, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open root group for read"); + HGOTO_ERROR_FF(FAIL, "can't open root group for read"); } else { - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create root group"); + HGOTO_ERROR_FF(FAIL, "can't create root group"); } /* for the process that succeeded in creating the group, create @@ -150,19 +150,19 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, ret = iod_obj_create(coh, first_tid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &mdkv_id, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* create the attribute KV object for the root group */ ret = iod_obj_create(coh, first_tid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &attrkv_id, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create attribute KV object"); + HGOTO_ERROR_FF(FAIL, "can't create attribute KV object"); /* create the KV object to hold each client's indexes for object OIDs after each trans_finish and file_close */ ret = iod_obj_create(coh, first_tid, NULL, IOD_OBJ_KV, NULL, NULL, &oidkv_id, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create array for OID indexes"); + HGOTO_ERROR_FF(FAIL, "can't create array for OID indexes"); /* set values for the scratch pad object */ sp[0] = mdkv_id; @@ -178,22 +178,22 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, /* set scratch pad in root group */ ret = iod_obj_set_scratch(root_oh.wr_oh, first_tid, &sp, &sp_cs, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } else { ret = iod_obj_set_scratch(root_oh.wr_oh, first_tid, &sp, NULL, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } /* Store Metadata in scratch pad */ ret = iod_obj_open_write(coh, input->mdkv_id, first_tid, NULL, &mdkv_oh, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open metadata KV"); + HGOTO_ERROR_FF(FAIL, "can't open metadata KV"); /* insert plist metadata */ if(H5VL_iod_insert_plist(mdkv_oh, first_tid, fcpl_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't insert link count KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert link count KV value"); kv.value = &value; kv.value_len = sizeof(uint64_t); @@ -207,12 +207,12 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(kv.value, kv.value_len); ret = iod_kv_set(mdkv_oh, first_tid, NULL, &kv, cs, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { ret = iod_kv_set(mdkv_oh, first_tid, NULL, &kv, NULL, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } kv.key = (void *)H5VL_IOD_KEY_ARRAY_IDS_INDEX; @@ -224,12 +224,12 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(kv.value, kv.value_len); ret = iod_kv_set(mdkv_oh, first_tid, NULL, &kv, cs, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { ret = iod_kv_set(mdkv_oh, first_tid, NULL, &kv, NULL, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } kv.key = (void *)H5VL_IOD_KEY_BLOB_IDS_INDEX; @@ -241,23 +241,23 @@ H5VL_iod_server_file_create_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(kv.value, kv.value_len); ret = iod_kv_set(mdkv_oh, first_tid, NULL, &kv, cs, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { ret = iod_kv_set(mdkv_oh, first_tid, NULL, &kv, NULL, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } ret = iod_obj_close(mdkv_oh, NULL, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close root object handle"); + HGOTO_ERROR_FF(FAIL, "can't close root object handle"); } /* Finish the transaction */ ret = iod_trans_finish(coh, first_tid, NULL, 0, NULL); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't finish transaction 1"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction 1"); output.coh.cookie = coh.cookie; output.root_oh.rd_oh = root_oh.rd_oh; @@ -338,7 +338,7 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, else if(H5F_ACC_RDONLY == mode) mode = IOD_CONT_R; else - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "invalid mode"); + HGOTO_ERROR_FF(FAIL, "invalid mode"); /* MSC - can't open file read only since IOD will fail when object are opened for write */ @@ -346,7 +346,7 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, mode = IOD_CONT_RW; if(H5Pget_metadata_integrity_scope(input->fapl_id, &cs_scope) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); /* scratch pad integrity in the container */ if(cs_scope & H5_CHECKSUM_IOD) { @@ -357,57 +357,57 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, /* open the container */ if(iod_container_open(input->name, con_open_hint, mode, &coh, NULL /*event*/)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open file"); + HGOTO_ERROR_FF(FAIL, "can't open file"); if(iod_query_cont_trans_stat(coh, &tids, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get container tids status"); + HGOTO_ERROR_FF(FAIL, "can't get container tids status"); rtid = tids->latest_rdable; if(iod_free_cont_trans_stat(coh, tids) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free container transaction status object"); + HGOTO_ERROR_FF(FAIL, "can't free container transaction status object"); if(iod_trans_start(coh, &rtid, NULL, num_peers, IOD_TRANS_R, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't start transaction"); + HGOTO_ERROR_FF(FAIL, "can't start transaction"); /* open the root group */ if ((ret = iod_obj_open_read(coh, ROOT_ID, rtid, NULL, &root_oh.rd_oh, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open root object for read"); + HGOTO_ERROR_FF(FAIL, "can't open root object for read"); } if ((ret = iod_obj_open_write(coh, ROOT_ID, rtid, NULL, &root_oh.wr_oh, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open root object for write"); + HGOTO_ERROR_FF(FAIL, "can't open root object for write"); } /* get scratch pad of root group */ if((ret = iod_obj_get_scratch(root_oh.rd_oh, rtid, &sp, &sp_cs, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for root object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for root object"); } if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV object */ if (iod_obj_open_read(coh, sp[0], rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MD KV"); + HGOTO_ERROR_FF(FAIL, "can't open MD KV"); /* retrieve all metadata from scratch pad */ if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.fcpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve fcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve fcpl"); /* open the OID indexes KV object */ if (iod_obj_open_read(coh, sp[2], rtid, NULL, &oidkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open OID KV"); + HGOTO_ERROR_FF(FAIL, "can't open OID KV"); ret = iod_kv_get_num(oidkv_oh, rtid, &num_entries, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't get number of KV entries"); + HGOTO_ERROR_FF(FAIL, "can't get number of KV entries"); val_size = sizeof(uint64_t); @@ -437,7 +437,7 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, ret = iod_kv_get_list(oidkv_oh, rtid, NULL, 0, &num_entries, kvs, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't get KV list from OID KV"); + HGOTO_ERROR_FF(FAIL, "can't get KV list from OID KV"); for(i=0 ; i<num_entries ; i++) { uint64_t *oid_index = (uint64_t *)kv[i].value; @@ -472,31 +472,31 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, key_size = strlen(H5VL_IOD_KEY_KV_IDS_INDEX); if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_KV_IDS_INDEX, key_size, &output.kv_oid_index, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "KV index lookup failed"); + HGOTO_ERROR_FF(FAIL, "KV index lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_KV_IDS_INDEX, key_size, &output.kv_oid_index, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } key_size = strlen(H5VL_IOD_KEY_ARRAY_IDS_INDEX); if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_ARRAY_IDS_INDEX, key_size, &output.array_oid_index, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Array index lookup failed"); + HGOTO_ERROR_FF(FAIL, "Array index lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_ARRAY_IDS_INDEX, key_size, &output.array_oid_index, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } key_size = strlen(H5VL_IOD_KEY_BLOB_IDS_INDEX); if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_BLOB_IDS_INDEX, key_size, &output.blob_oid_index, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "BLOB index lookup failed"); + HGOTO_ERROR_FF(FAIL, "BLOB index lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_BLOB_IDS_INDEX, key_size, &output.blob_oid_index, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } if(iod_cs) { @@ -507,10 +507,10 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, /* close the oid KV */ if(iod_obj_close(oidkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close OID KV"); + HGOTO_ERROR_FF(FAIL, "can't close OID KV"); /* close the metadata KV */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close MD KV"); + HGOTO_ERROR_FF(FAIL, "can't close MD KV"); output.coh.cookie = coh.cookie; output.root_id = ROOT_ID; @@ -525,7 +525,7 @@ H5VL_iod_server_file_open_cb(AXE_engine_t UNUSED axe_engine, if(TRUE != acquire) { output.c_version = IOD_TID_UNKNOWN; if(iod_trans_finish(coh, rtid, NULL, 0, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't finish transaction 0"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction 0"); } #if H5_EFF_DEBUG @@ -602,13 +602,13 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, uint32_t cs_scope = input->cs_scope; if(iod_query_cont_trans_stat(coh, &tids, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get container tids status"); + HGOTO_ERROR_FF(FAIL, "can't get container tids status"); trans_num = tids->latest_wrting + 1; rtid = tids->latest_rdable; if(iod_free_cont_trans_stat(coh, tids) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free container transaction status object"); + HGOTO_ERROR_FF(FAIL, "can't free container transaction status object"); #if H5_EFF_DEBUG fprintf(stderr, "File Close starting transaction %"PRIu64" rcxt %"PRIu64"\n", @@ -617,29 +617,29 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, if((ret = iod_trans_start(coh, &rtid, NULL, 1, IOD_TRANS_R, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't start READ transaction"); + HGOTO_ERROR_FF(FAIL, "can't start READ transaction"); } if((ret = iod_trans_start(coh, &trans_num, NULL, 1, IOD_TRANS_W, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't start WRITE transaction"); + HGOTO_ERROR_FF(FAIL, "can't start WRITE transaction"); } /* get scratch pad of root group */ if((ret = iod_obj_get_scratch(root_oh.rd_oh, rtid, &sp, &sp_cs, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for root object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for root object"); } if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV object */ if (iod_obj_open_write(coh, sp[0], trans_num, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open metadata KV"); + HGOTO_ERROR_FF(FAIL, "can't open metadata KV"); /* insert current indexes in the metadata KV object */ kv.value = &input->max_kv_index; @@ -653,11 +653,11 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, trans_num, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, trans_num, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } @@ -672,11 +672,11 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, trans_num, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, trans_num, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } kv.value = &input->max_blob_index; @@ -690,15 +690,15 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, trans_num, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, trans_num, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close root object handle"); + HGOTO_ERROR_FF(FAIL, "can't close root object handle"); /* open the OID kv object and remove all entries since this is a clean shutdown and the summary is stored in the metadata @@ -712,13 +712,13 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, iod_ret_t *oid_ret = NULL; if (iod_obj_open_write(coh, sp[2], trans_num, NULL, &oidkv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open oid KV"); + HGOTO_ERROR_FF(FAIL, "can't open oid KV"); if (iod_obj_open_read(coh, sp[2], rtid, NULL, &oidkv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open oid KV"); + HGOTO_ERROR_FF(FAIL, "can't open oid KV"); ret = iod_kv_get_num(oidkv_oh.rd_oh, rtid, &num_entries, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't get number of KV entries"); + HGOTO_ERROR_FF(FAIL, "can't get number of KV entries"); #if H5_EFF_DEBUG fprintf(stderr, "NUM entries in OID index KV = %d\n", num_entries); @@ -740,11 +740,11 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, ret = iod_kv_list_key(oidkv_oh.rd_oh, rtid, NULL, 0, &num_entries, kvs, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't get list of keys"); + HGOTO_ERROR_FF(FAIL, "can't get list of keys"); ret = iod_kv_unlink_keys(oidkv_oh.wr_oh, trans_num, NULL, num_entries, kvs, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't unlink keys in OID index KV"); + HGOTO_ERROR_FF(FAIL, "can't unlink keys in OID index KV"); for(i=0 ; i<num_entries ; i++) free(oid_kv[i].key); @@ -755,18 +755,18 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, } if(iod_obj_close(oidkv_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object handle"); + HGOTO_ERROR_FF(FAIL, "can't close object handle"); if(iod_obj_close(oidkv_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object handle"); + HGOTO_ERROR_FF(FAIL, "can't close object handle"); } /* finish the transaction */ if(iod_trans_finish(coh, rtid, NULL, 0, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't finish transaction"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction"); /* finish the transaction */ if(iod_trans_finish(coh, trans_num, NULL, 0, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't finish transaction"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction"); if(TRUE == input->persist_on_close) { #if H5_EFF_DEBUG @@ -775,7 +775,7 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, /* persist the last transaction */ if((ret = iod_trans_persist(coh, trans_num, NULL, NULL)) < 0) { fprintf(stderr, "iod_trans_persist failed. %d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't persist before closing container"); + HGOTO_ERROR_FF(FAIL, "can't persist before closing container"); } } } @@ -787,9 +787,9 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, /* close the root group */ if(iod_obj_close(root_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "can't close root object handle"); + HGOTO_ERROR_FF(FAIL, "can't close root object handle"); if(iod_obj_close(root_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "can't close root object handle"); + HGOTO_ERROR_FF(FAIL, "can't close root object handle"); #if H5_EFF_DEBUG fprintf(stderr, "Closing Container: %"PRIu64"\n", coh.cookie); @@ -798,7 +798,7 @@ H5VL_iod_server_file_close_cb(AXE_engine_t UNUSED axe_engine, /* close the container */ if((ret = iod_container_close(coh, NULL, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_FILE, H5E_CANTDEC, FAIL, "can't close container"); + HGOTO_ERROR_FF(FAIL, "can't close container"); } done: @@ -806,7 +806,7 @@ done: fprintf(stderr, "Done with file close, sending response to client\n"); #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "can't send result of file close to client"); + HDONE_ERROR_FF(FAIL, "can't send result of file close to client"); input = (file_close_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); diff --git a/src/H5VLiod_group.c b/src/H5VLiod_group.c index 26ca074..0a85c0a 100644 --- a/src/H5VLiod_group.c +++ b/src/H5VLiod_group.c @@ -79,7 +79,7 @@ H5VL_iod_server_group_create_cb(AXE_engine_t UNUSED axe_engine, /* get the scope for data integrity checks */ if(H5Pget_ocpl_enable_checksum(gcpl_id, &enable_checksum) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); if((cs_scope & H5_CHECKSUM_IOD) && enable_checksum) { obj_create_hint = (iod_hint_list_t *)malloc(sizeof(iod_hint_list_t) + sizeof(iod_hint_t)); @@ -92,7 +92,7 @@ H5VL_iod_server_group_create_cb(AXE_engine_t UNUSED axe_engine, does not exist. */ if(H5VL_iod_server_traverse(coh, loc_id, loc_handle, name, wtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); #if H5_EFF_DEBUG fprintf(stderr, "Creating Group ID %"PRIx64" (CV %"PRIu64", TR %"PRIu64") ", @@ -107,15 +107,15 @@ H5VL_iod_server_group_create_cb(AXE_engine_t UNUSED axe_engine, /* create the group */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &grp_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create Group"); + HGOTO_ERROR_FF(FAIL, "can't create Group"); if((ret = iod_obj_open_read(coh, grp_id, wtid, NULL, &grp_oh.rd_oh, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open Group for read"); + HGOTO_ERROR_FF(FAIL, "can't open Group for read"); } if((ret = iod_obj_open_write(coh, grp_id, wtid, NULL, &grp_oh.wr_oh, NULL)) < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open Group for write"); + HGOTO_ERROR_FF(FAIL, "can't open Group for write"); } step += 1; @@ -123,12 +123,12 @@ H5VL_iod_server_group_create_cb(AXE_engine_t UNUSED axe_engine, /* create the metadata KV object for the group */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &mdkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* create the attribute KV object for the group */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &attrkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* set values for the scratch pad object */ sp[0] = mdkv_id; @@ -142,45 +142,45 @@ H5VL_iod_server_group_create_cb(AXE_engine_t UNUSED axe_engine, sp_cs = H5_checksum_crc64(&sp, sizeof(sp)); if (iod_obj_set_scratch(grp_oh.wr_oh, wtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } else { if (iod_obj_set_scratch(grp_oh.wr_oh, wtid, &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } /* store metadata */ /* Open Metadata KV object for write */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't create scratch pad"); step ++; /* insert plist metadata */ if(H5VL_iod_insert_plist(mdkv_oh, wtid, gcpl_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh, wtid, (uint64_t)1, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert object type metadata */ if(H5VL_iod_insert_object_type(mdkv_oh, wtid, H5I_GROUP, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close Metadata KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); step --; /* add link in parent group to current object */ if(H5VL_iod_insert_new_link(cur_oh.wr_oh, wtid, last_comp, H5L_TYPE_HARD, &grp_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); #if H5_EFF_DEBUG fprintf(stderr, "Done with group create, sending response to client\n"); @@ -281,42 +281,42 @@ H5VL_iod_server_group_open_cb(AXE_engine_t UNUSED axe_engine, grp_id = ROOT_ID; /* open a write handle on the ID. */ if(iod_obj_open_read(coh, grp_id, rtid, NULL, &grp_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); } else { /* Traverse Path and open group */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, name, rtid, cs_scope, &grp_id, &grp_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); } /* open a write handle on the ID. */ if(iod_obj_open_write(coh, grp_id, rtid, NULL, &grp_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); step ++; /* get scratch pad of group */ if(iod_obj_get_scratch(grp_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_read(coh, sp[0], rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); step ++; if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.gcpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve gcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve gcpl"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close meta data KV handle"); + HGOTO_ERROR_FF(FAIL, "can't close meta data KV handle"); step --; output.iod_id = grp_id; @@ -386,13 +386,13 @@ H5VL_iod_server_group_close_cb(AXE_engine_t UNUSED axe_engine, if(IOD_OH_UNDEFINED == iod_oh.wr_oh.cookie || IOD_OH_UNDEFINED == iod_oh.rd_oh.cookie) { - HGOTO_ERROR2(H5E_SYM, H5E_CANTCLOSEOBJ, FAIL, "can't close object with invalid handle"); + HGOTO_ERROR_FF(FAIL, "can't close object with invalid handle"); } if((iod_obj_close(iod_oh.rd_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if((iod_obj_close(iod_oh.wr_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); done: #if H5_EFF_DEBUG diff --git a/src/H5VLiod_index.c b/src/H5VLiod_index.c index ffacd57..f9ae1af 100644 --- a/src/H5VLiod_index.c +++ b/src/H5VLiod_index.c @@ -61,7 +61,7 @@ H5VL_iod_server_dset_set_index_info_cb(AXE_engine_t UNUSED axe_engine, /* Open Metadata KV object for write */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open MDKV object"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV object"); kv.key = H5VL_IOD_IDX_PLUGIN_ID; kv.key_len = (iod_size_t)strlen(H5VL_IOD_IDX_PLUGIN_ID); @@ -74,11 +74,11 @@ H5VL_iod_server_dset_set_index_info_cb(AXE_engine_t UNUSED axe_engine, cs[0] = H5_checksum_crc64(kv.key, kv.key_len); cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } kv.key = H5VL_IOD_IDX_PLUGIN_MD; @@ -92,11 +92,11 @@ H5VL_iod_server_dset_set_index_info_cb(AXE_engine_t UNUSED axe_engine, cs[0] = H5_checksum_crc64(kv.key, kv.key_len); cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } #if H5_EFF_DEBUG @@ -105,11 +105,11 @@ H5VL_iod_server_dset_set_index_info_cb(AXE_engine_t UNUSED axe_engine, done: if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); /* close the Metadata KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); input = (dset_set_index_info_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -157,7 +157,7 @@ H5VL_iod_server_dset_get_index_info_cb(AXE_engine_t UNUSED axe_engine, /* Open Metadata KV object for write */ if (iod_obj_open_read(coh, mdkv_id, rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open MDKV object"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV object"); if(cs_scope & H5_CHECKSUM_IOD) { iod_cs = (iod_checksum_t *)malloc(sizeof(iod_checksum_t) * 2); @@ -181,7 +181,7 @@ H5VL_iod_server_dset_get_index_info_cb(AXE_engine_t UNUSED axe_engine, HGOTO_DONE(SUCCEED); } fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); } if(cs_scope & H5_CHECKSUM_IOD) { iod_checksum_t cs[2]; @@ -190,7 +190,7 @@ H5VL_iod_server_dset_get_index_info_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(&output.idx_plugin_id, val_size); if(iod_cs[0] != cs[0] && iod_cs[1] != cs[1]) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } @@ -200,14 +200,14 @@ H5VL_iod_server_dset_get_index_info_cb(AXE_engine_t UNUSED axe_engine, if(iod_kv_get_value(mdkv_oh, rtid, key, key_size, NULL, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); output.idx_metadata.buf_size = val_size; output.idx_metadata.buf = malloc(val_size); if(iod_kv_get_value(mdkv_oh, rtid, key, key_size, (char *)output.idx_metadata.buf, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { iod_checksum_t cs[2]; @@ -216,7 +216,7 @@ H5VL_iod_server_dset_get_index_info_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(output.idx_metadata.buf, val_size); if(iod_cs[0] != cs[0] && iod_cs[1] != cs[1]) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } output.ret = ret_value; @@ -247,7 +247,7 @@ done: /* close the Metadata KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); input = (dset_get_index_info_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -292,7 +292,7 @@ H5VL_iod_server_dset_remove_index_info_cb(AXE_engine_t UNUSED axe_engine, /* Open Metadata KV object for write */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open MDKV object"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV object"); kv.key = H5VL_IOD_IDX_PLUGIN_ID; kv.key_len = (iod_size_t)strlen(H5VL_IOD_IDX_PLUGIN_ID); @@ -300,7 +300,7 @@ H5VL_iod_server_dset_remove_index_info_cb(AXE_engine_t UNUSED axe_engine, kvs.cs = NULL; kvs.ret = &ret; if(iod_kv_unlink_keys(mdkv_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); kv.key = H5VL_IOD_IDX_PLUGIN_MD; kv.key_len = (iod_size_t)strlen(H5VL_IOD_IDX_PLUGIN_MD); @@ -308,7 +308,7 @@ H5VL_iod_server_dset_remove_index_info_cb(AXE_engine_t UNUSED axe_engine, kvs.cs = NULL; kvs.ret = &ret; if(iod_kv_unlink_keys(mdkv_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); #if H5_EFF_DEBUG fprintf(stderr, "Done with dataset rm_index_info, sending response to client\n"); @@ -316,11 +316,11 @@ H5VL_iod_server_dset_remove_index_info_cb(AXE_engine_t UNUSED axe_engine, done: if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); /* close the Metadata KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); input = (dset_rm_index_info_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); diff --git a/src/H5VLiod_link.c b/src/H5VLiod_link.c index 7e22e8e..4495ae7 100644 --- a/src/H5VLiod_link.c +++ b/src/H5VLiod_link.c @@ -67,7 +67,7 @@ H5VL_iod_server_link_create_cb(AXE_engine_t UNUSED axe_engine, does not exist. */ if(H5VL_iod_server_traverse(coh, input->loc_id, input->loc_oh, input->loc_name, wtid, rtid, FALSE, cs_scope, &src_last_comp, &src_id, &src_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); #if H5_EFF_DEBUG fprintf(stderr, "new link name = %s\n", src_last_comp); @@ -84,67 +84,67 @@ H5VL_iod_server_link_create_cb(AXE_engine_t UNUSED axe_engine, /* Try and open the starting location */ if (iod_obj_open_read(coh, input->target_loc_id, wtid, NULL, &input->target_loc_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open start location"); + HGOTO_ERROR_FF(FAIL, "can't open start location"); opened_locally = TRUE; } /* Traverse Path and open the target object */ if(H5VL_iod_server_open_path(coh, input->target_loc_id, input->target_loc_oh, input->target_name, rtid, cs_scope, &target_id, &target_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* add link in parent group to current object */ if(H5VL_iod_insert_new_link(src_oh.wr_oh, wtid, src_last_comp, H5L_TYPE_HARD, &target_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); if(input->target_loc_id != target_id) { /* get scratch pad */ if(iod_obj_get_scratch(target_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } else { /* open the metadata KV */ if (iod_obj_open_read(coh, input->target_mdkv_id, rtid, NULL, &mdkv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, input->target_mdkv_id, rtid, NULL, &mdkv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); } if(H5VL_iod_get_metadata(mdkv_oh.rd_oh, rtid, H5VL_IOD_LINK_COUNT, H5VL_IOD_KEY_OBJ_LINK_COUNT, cs_scope, NULL, &link_count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); link_count ++; /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh.wr_oh, wtid, link_count, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(iod_obj_close(mdkv_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* close the target location */ if(TRUE == opened_locally || input->target_loc_oh.rd_oh.cookie != target_oh.rd_oh.cookie) { if(iod_obj_close(target_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } } else if(H5VL_LINK_CREATE_SOFT == create_type) { @@ -152,23 +152,23 @@ H5VL_iod_server_link_create_cb(AXE_engine_t UNUSED axe_engine, if(H5VL_iod_insert_new_link(src_oh.wr_oh, wtid, src_last_comp, H5L_TYPE_SOFT, input->link_value, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); #if H5_EFF_DEBUG fprintf(stderr, "Soft link Value = %s\n", input->link_value); #endif } else - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Invalid Link type"); + HGOTO_ERROR_FF(FAIL, "Invalid Link type"); /* close the source location */ if(input->loc_oh.rd_oh.cookie != src_oh.rd_oh.cookie) { if(iod_obj_close(src_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } if(input->loc_oh.wr_oh.cookie != src_oh.wr_oh.cookie) { if(iod_obj_close(src_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } done: @@ -235,7 +235,7 @@ H5VL_iod_server_link_move_cb(AXE_engine_t UNUSED axe_engine, if(H5VL_iod_server_traverse(coh, input->src_loc_id, input->src_loc_oh, input->src_loc_name, wtid, rtid, FALSE, cs_scope, &src_last_comp, &src_id, &src_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); /* the traversal will retrieve the location where the link needs to be moved/copied to. The traversal will fail if an intermediate group @@ -243,25 +243,25 @@ H5VL_iod_server_link_move_cb(AXE_engine_t UNUSED axe_engine, if(H5VL_iod_server_traverse(coh, input->dst_loc_id, input->dst_loc_oh, input->dst_loc_name, wtid, rtid, FALSE, cs_scope, &dst_last_comp, &dst_id, &dst_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); /* get the link value */ if(H5VL_iod_get_metadata(src_oh.rd_oh, rtid, H5VL_IOD_LINK, src_last_comp, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); /* Insert object in the destination path */ if(H5L_TYPE_HARD == iod_link.link_type) { if(H5VL_iod_insert_new_link(dst_oh.wr_oh, wtid, dst_last_comp, iod_link.link_type, &iod_link.u.iod_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); } else if(H5L_TYPE_SOFT == iod_link.link_type) { if(H5VL_iod_insert_new_link(dst_oh.wr_oh, wtid, dst_last_comp, iod_link.link_type, &iod_link.u.symbolic_name, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); } /* if the operation type is a Move, remove the KV pair from the source object */ @@ -278,7 +278,7 @@ H5VL_iod_server_link_move_cb(AXE_engine_t UNUSED axe_engine, /* remove link from source object */ if(iod_kv_unlink_keys(src_oh.wr_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); } /* adjust link count on target object */ @@ -291,44 +291,44 @@ H5VL_iod_server_link_move_cb(AXE_engine_t UNUSED axe_engine, /* open the current group */ if (iod_obj_open_read(coh, iod_link.u.iod_id, rtid, NULL, &target_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); /* get scratch pad */ if(iod_obj_get_scratch(target_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if(H5VL_iod_get_metadata(mdkv_oh.rd_oh, rtid, H5VL_IOD_LINK_COUNT, H5VL_IOD_KEY_OBJ_LINK_COUNT, cs_scope, NULL, &link_count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); link_count ++; /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh.wr_oh, wtid, link_count, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(iod_obj_close(mdkv_oh.wr_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* close the target location */ if(iod_obj_close(target_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); } /* close source group if it is not the location we started the @@ -436,7 +436,7 @@ H5VL_iod_server_link_exists_cb(AXE_engine_t UNUSED axe_engine, } else { if(iod_obj_close(rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); ret = TRUE; } } @@ -504,7 +504,7 @@ H5VL_iod_server_link_get_info_cb(AXE_engine_t UNUSED axe_engine, to be checked */ if(H5VL_iod_server_traverse(coh, loc_id, loc_oh, loc_name, rtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); #if H5_EFF_DEBUG fprintf(stderr, "Link Get_Info on link %s\n", last_comp); @@ -513,7 +513,7 @@ H5VL_iod_server_link_get_info_cb(AXE_engine_t UNUSED axe_engine, /* lookup link information in the current location */ if(H5VL_iod_get_metadata(cur_oh.rd_oh, rtid, H5VL_IOD_LINK, last_comp, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); /* setup link info */ linfo.type = iod_link.link_type; @@ -529,7 +529,7 @@ H5VL_iod_server_link_get_info_cb(AXE_engine_t UNUSED axe_engine, case H5L_TYPE_EXTERNAL: case H5L_TYPE_MAX: default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "unsuppored link type"); + HGOTO_ERROR_FF(FAIL, "unsuppored link type"); } #if H5_EFF_DEBUG @@ -606,7 +606,7 @@ H5VL_iod_server_link_get_val_cb(AXE_engine_t UNUSED axe_engine, to be checked */ if(H5VL_iod_server_traverse(coh, loc_id, loc_oh, loc_name, rtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); #if H5_EFF_DEBUG fprintf(stderr, "Link Get_val on link %s\n", last_comp); @@ -615,17 +615,17 @@ H5VL_iod_server_link_get_val_cb(AXE_engine_t UNUSED axe_engine, /* lookup link information in the current location */ if(H5VL_iod_get_metadata(cur_oh.rd_oh, rtid, H5VL_IOD_LINK, last_comp, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); if(H5L_TYPE_SOFT != iod_link.link_type) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "link is not SOFT"); + HGOTO_ERROR_FF(FAIL, "link is not SOFT"); output.value.val_size = length; output.value.val = NULL; if(length) { if(NULL == (output.value.val = (void *)malloc (length))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); memcpy(output.value.val, iod_link.u.symbolic_name, length); } @@ -720,12 +720,12 @@ H5VL_iod_server_link_remove_cb(AXE_engine_t UNUSED axe_engine, does not exist. */ if(H5VL_iod_server_traverse(coh, loc_id, loc_oh, loc_name, wtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); /* lookup object ID in the current location */ if(H5VL_iod_get_metadata(cur_oh.rd_oh, rtid, H5VL_IOD_LINK, last_comp, cs_scope, NULL, &iod_link) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); /* unlink object from conainer */ kv.key = last_comp; @@ -734,7 +734,7 @@ H5VL_iod_server_link_remove_cb(AXE_engine_t UNUSED axe_engine, kvs.cs = &cs; kvs.ret = &ret; if(iod_kv_unlink_keys(cur_oh.wr_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); /* check the metadata information for the object and remove it from the container if this is the last link to it */ @@ -748,32 +748,32 @@ H5VL_iod_server_link_remove_cb(AXE_engine_t UNUSED axe_engine, /* open the current group */ if (iod_obj_open_read(coh, obj_id, rtid, NULL, &obj_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); step ++; /* get scratch pad */ if(iod_obj_get_scratch(obj_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if (iod_obj_open_write(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); step ++; if(H5VL_iod_get_metadata(mdkv_oh.rd_oh, rtid, H5VL_IOD_LINK_COUNT, H5VL_IOD_KEY_OBJ_LINK_COUNT, cs_scope, NULL, &link_count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); link_count --; @@ -782,7 +782,7 @@ H5VL_iod_server_link_remove_cb(AXE_engine_t UNUSED axe_engine, /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh.wr_oh, wtid, link_count, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); } iod_obj_close(mdkv_oh.rd_oh, NULL, NULL); @@ -797,11 +797,11 @@ H5VL_iod_server_link_remove_cb(AXE_engine_t UNUSED axe_engine, /* If this was the only link to the object, remove the object */ if(0 == link_count) { if(iod_obj_unlink(coh, obj_id, wtid, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink object"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink object"); if(iod_obj_unlink(coh, sp[0], wtid, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink MDKV object"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink MDKV object"); if(iod_obj_unlink(coh, sp[1], wtid, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink ATTRKV object"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink ATTRKV object"); } } diff --git a/src/H5VLiod_map.c b/src/H5VLiod_map.c index 8be68e4..e026401 100644 --- a/src/H5VLiod_map.c +++ b/src/H5VLiod_map.c @@ -84,7 +84,7 @@ H5VL_iod_server_map_create_cb(AXE_engine_t UNUSED axe_engine, /* get the scope for data integrity checks for raw data */ if(H5Pget_ocpl_enable_checksum(mcpl_id, &enable_checksum) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); if((cs_scope & H5_CHECKSUM_IOD) && enable_checksum) { obj_create_hint = (iod_hint_list_t *)malloc(sizeof(iod_hint_list_t) + sizeof(iod_hint_t)); @@ -97,7 +97,7 @@ H5VL_iod_server_map_create_cb(AXE_engine_t UNUSED axe_engine, does not exist. */ if(H5VL_iod_server_traverse(coh, loc_id, loc_handle, name, wtid, rtid, FALSE, cs_scope, &last_comp, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); #if H5_EFF_DEBUG fprintf(stderr, "Creating Map ID %"PRIx64" (CV %"PRIu64", TR %"PRIu64") ", @@ -112,24 +112,24 @@ H5VL_iod_server_map_create_cb(AXE_engine_t UNUSED axe_engine, /* create the map */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &map_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create Map"); + HGOTO_ERROR_FF(FAIL, "can't create Map"); if (iod_obj_open_read(coh, map_id, wtid, NULL, &map_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open Map"); + HGOTO_ERROR_FF(FAIL, "can't open Map"); if (iod_obj_open_write(coh, map_id, wtid, NULL, &map_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open Map"); + HGOTO_ERROR_FF(FAIL, "can't open Map"); step ++; /* create the metadata KV object for the map */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &mdkv_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* create the attribute KV object for the root group */ if(iod_obj_create(coh, wtid, obj_create_hint, IOD_OBJ_KV, NULL, NULL, &attr_id, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create metadata KV object"); + HGOTO_ERROR_FF(FAIL, "can't create metadata KV object"); /* set values for the scratch pad object */ sp[0] = mdkv_id; @@ -143,54 +143,54 @@ H5VL_iod_server_map_create_cb(AXE_engine_t UNUSED axe_engine, sp_cs = H5_checksum_crc64(&sp, sizeof(sp)); if (iod_obj_set_scratch(map_oh.wr_oh, wtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } else { if (iod_obj_set_scratch(map_oh.wr_oh, wtid, &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't set scratch pad"); } /* Open Metadata KV object for write */ if (iod_obj_open_write(coh, mdkv_id, wtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't create scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't create scratch pad"); step ++; /* insert plist metadata */ if(H5VL_iod_insert_plist(mdkv_oh, wtid, mcpl_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert link count metadata */ if(H5VL_iod_insert_link_count(mdkv_oh, wtid, (uint64_t)1, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert object type metadata */ if(H5VL_iod_insert_object_type(mdkv_oh, wtid, H5I_MAP, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert Key datatype metadata */ if(H5VL_iod_insert_datatype_with_key(mdkv_oh, wtid, keytype, H5VL_IOD_KEY_MAP_KEY_TYPE, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* insert Value datatype metadata */ if(H5VL_iod_insert_datatype_with_key(mdkv_oh, wtid, valtype, H5VL_IOD_KEY_MAP_VALUE_TYPE, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close MD KV object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); step --; /* add link in parent group to current object */ if(H5VL_iod_insert_new_link(cur_oh.wr_oh, wtid, last_comp, H5L_TYPE_HARD, &map_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); #if H5_EFF_DEBUG fprintf(stderr, "Done with map create, sending response to client\n"); @@ -288,45 +288,45 @@ H5VL_iod_server_map_open_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open map */ if(H5VL_iod_server_open_path(coh, loc_id, loc_handle, name, rtid, cs_scope, &map_id, &map_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* open a write handle on the ID. */ if (iod_obj_open_write(coh, map_id, rtid, NULL, &map_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current map"); + HGOTO_ERROR_FF(FAIL, "can't open current map"); step ++; /* get scratch pad of map */ if(iod_obj_get_scratch(map_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); step ++; if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.mcpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve gcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve gcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_MAP_KEY_TYPE, cs_scope, NULL, &output.keytype_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_MAP_VALUE_TYPE, cs_scope, NULL, &output.valtype_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close meta data KV handle"); + HGOTO_ERROR_FF(FAIL, "can't close meta data KV handle"); step --; output.iod_id = map_id; @@ -422,7 +422,7 @@ H5VL_iod_server_map_set_cb(AXE_engine_t UNUSED axe_engine, /* open the map if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_write(coh, iod_id, wtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } @@ -435,25 +435,25 @@ H5VL_iod_server_map_set_cb(AXE_engine_t UNUSED axe_engine, /* allocate buffer to hold data */ if(NULL == (val_buf = malloc(val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* create a Mercury block handle for transfer */ HG_Bulk_handle_create(val_buf, val_size, HG_BULK_READWRITE, &bulk_block_handle); /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_read_all(source, value_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't get data from function shipper"); + HGOTO_ERROR_FF(FAIL, "can't get data from function shipper"); /* free the bds block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); /* get the scope for data integrity checks for raw data */ if(H5Pget_rawdata_integrity_scope(dxpl_id, &raw_cs_scope) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); /* verify data if transfer flag is set */ if(raw_cs_scope & H5_CHECKSUM_TRANSFER) { @@ -476,11 +476,11 @@ H5VL_iod_server_map_set_cb(AXE_engine_t UNUSED axe_engine, /* adjust buffers for datatype conversion */ if(H5VL__iod_server_adjust_buffer(key_memtype_id, key_maptype_id, 1, dxpl_id, key.buf_size, &key.buf, &key_is_vl_data, &key_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); if(H5VL__iod_server_adjust_buffer(val_memtype_id, val_maptype_id, 1, dxpl_id, val_size, &val_buf, &val_is_vl_data, &new_val_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); #if H5_EFF_DEBUG /* fake debugging */ @@ -510,11 +510,11 @@ H5VL_iod_server_map_set_cb(AXE_engine_t UNUSED axe_engine, if(!key_is_vl_data) { /* convert data if needed */ if(H5Tconvert(key_memtype_id, key_maptype_id, 1, key.buf, NULL, dxpl_id) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); } if(!val_is_vl_data) { if(H5Tconvert(val_memtype_id, val_maptype_id, 1, val_buf, NULL, dxpl_id) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); } /* MSC - do IOD checksum - can't now */ @@ -531,17 +531,17 @@ H5VL_iod_server_map_set_cb(AXE_engine_t UNUSED axe_engine, cs[0] = H5_checksum_crc64(kv.key, kv.key_len); cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(iod_oh, wtid, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in Map"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in Map"); } else { if (iod_kv_set(iod_oh, wtid, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in Map"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in Map"); } done: if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_WRITEERROR, FAIL, "can't send result of write to client"); + HDONE_ERROR_FF(FAIL, "can't send result of write to client"); input = (map_set_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -552,7 +552,7 @@ done: /* close the map if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } #if H5_EFF_DEBUG @@ -618,7 +618,7 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, /* open the map if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, iod_id, rtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } @@ -631,7 +631,7 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, /* get replica ID from dxpl */ if(H5Pget_read_replica(dxpl_id, &read_tid) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get replica ID from dxpl"); + HGOTO_ERROR_FF(FAIL, "can't get replica ID from dxpl"); if(read_tid) { fprintf(stderr, "Reading from replica tag %"PRIx64"\n", read_tid); @@ -641,16 +641,16 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, /* get the scope for data integrity checks for raw data */ if(H5Pget_rawdata_integrity_scope(dxpl_id, &raw_cs_scope) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get scope for data integrity checks"); + HGOTO_ERROR_FF(FAIL, "can't get scope for data integrity checks"); /* adjust buffers for datatype conversion */ if(H5VL__iod_server_adjust_buffer(key_memtype_id, key_maptype_id, 1, dxpl_id, key.buf_size, &key.buf, &key_is_vl, &key_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); if(iod_kv_get_value(iod_oh, rtid, key.buf, (iod_size_t)key.buf_size, NULL, &src_size, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve value size from parent KV store"); + HGOTO_ERROR_FF(FAIL, "can't retrieve value size from parent KV store"); if(val_is_vl) { output.ret = ret_value; @@ -658,11 +658,11 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, fprintf(stderr, "val size = %zu\n", src_size); if(client_val_buf_size) { if(NULL == (val_buf = malloc((size_t)src_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate buffer"); if(iod_kv_get_value(iod_oh, rtid, key.buf, (iod_size_t)key.buf_size, val_buf, &src_size, kv_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve value from parent KV store"); + HGOTO_ERROR_FF(FAIL, "can't retrieve value from parent KV store"); if(raw_cs_scope) { iod_checksum_t cs[2]; @@ -671,7 +671,7 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(val_buf, src_size); if(kv_cs[0] != cs[0] && kv_cs[1] != cs[1]) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected in IOD KV pair"); + HGOTO_ERROR_FF(FAIL, "Corruption detected in IOD KV pair"); /* set checksum for the data to be sent */ output.val_cs = kv_cs[1]; @@ -687,14 +687,14 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(dest, value_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* free block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); } } else { @@ -702,11 +702,11 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, src_size = HG_Bulk_handle_get_size(value_handle); if(NULL == (val_buf = malloc((size_t)src_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate buffer"); if(iod_kv_get_value(iod_oh, rtid, key.buf, (iod_size_t)key.buf_size, val_buf, &src_size, kv_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve value from parent KV store"); + HGOTO_ERROR_FF(FAIL, "can't retrieve value from parent KV store"); if(raw_cs_scope) { iod_checksum_t cs[2]; @@ -715,7 +715,7 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, cs[1] = H5_checksum_crc64(val_buf, src_size); if(kv_cs[0] != cs[0] && kv_cs[1] != cs[1]) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected in IOD KV pair"); + HGOTO_ERROR_FF(FAIL, "Corruption detected in IOD KV pair"); /* set checksum for the data to be sent */ output.val_cs = kv_cs[1]; @@ -724,11 +724,11 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, /* adjust buffers for datatype conversion */ if(H5VL__iod_server_adjust_buffer(val_memtype_id, val_maptype_id, 1, dxpl_id, (size_t)src_size, &val_buf, &val_is_vl, &val_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); /* do data conversion */ if(H5Tconvert(val_maptype_id, val_memtype_id, 1, val_buf, NULL, dxpl_id) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); if(raw_cs_scope) { /* calculate a checksum for the data to be sent */ @@ -748,14 +748,14 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(dest, value_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* free block handle */ if(HG_SUCCESS != HG_Bulk_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); } #if H5_EFF_DEBUG @@ -763,7 +763,7 @@ H5VL_iod_server_map_get_cb(AXE_engine_t UNUSED axe_engine, #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &output)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map get"); + HGOTO_ERROR_FF(FAIL, "can't send result of map get"); done: @@ -772,7 +772,7 @@ done: output.val_size = 0; output.val_cs = 0; if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &output)) - HDONE_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map get"); + HDONE_ERROR_FF(FAIL, "can't send result of map get"); } if(val_buf) @@ -784,7 +784,7 @@ done: /* close the map if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_map_get_cb() */ @@ -828,12 +828,12 @@ H5VL_iod_server_map_get_count_cb(AXE_engine_t UNUSED axe_engine, /* open the map if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, iod_id, rtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } if(iod_kv_get_num(iod_oh, rtid, &num, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve Number of KV pairs in MAP"); + HGOTO_ERROR_FF(FAIL, "can't retrieve Number of KV pairs in MAP"); output = (hsize_t)num; @@ -842,14 +842,14 @@ H5VL_iod_server_map_get_count_cb(AXE_engine_t UNUSED axe_engine, #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &output)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map get"); + HGOTO_ERROR_FF(FAIL, "can't send result of map get"); done: if(ret_value < 0) { output = IOD_COUNT_UNDEFINED; if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &output)) - HDONE_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map get_count"); + HDONE_ERROR_FF(FAIL, "can't send result of map get_count"); } input = (map_get_count_in_t *)H5MM_xfree(input); @@ -858,7 +858,7 @@ done: /* close the map if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_map_get_count_cb() */ @@ -907,14 +907,14 @@ H5VL_iod_server_map_exists_cb(AXE_engine_t UNUSED axe_engine, /* open the map if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, iod_id, rtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } /* adjust buffers for datatype conversion */ if(H5VL__iod_server_adjust_buffer(key_memtype_id, key_maptype_id, 1, H5P_DEFAULT, key.buf_size, &key.buf, &is_vl_data, &key_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); /* determine if the Key exists by querying its value size */ if(iod_kv_get_value(iod_oh, rtid, key.buf, (iod_size_t)key.buf_size, NULL, @@ -929,14 +929,14 @@ H5VL_iod_server_map_exists_cb(AXE_engine_t UNUSED axe_engine, #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &exists)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map get"); + HGOTO_ERROR_FF(FAIL, "can't send result of map get"); done: if(ret_value < 0) { exists = -1; if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &exists)) - HDONE_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map exists"); + HDONE_ERROR_FF(FAIL, "can't send result of map exists"); } input = (map_op_in_t *)H5MM_xfree(input); @@ -945,7 +945,7 @@ done: /* close the map if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_map_exists_cb() */ @@ -994,14 +994,14 @@ H5VL_iod_server_map_delete_cb(AXE_engine_t UNUSED axe_engine, /* open the map if we don't have the handle yet */ if(iod_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_write(coh, iod_id, rtid, NULL /*hints*/, &iod_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } /* adjust buffers for datatype conversion */ if(H5VL__iod_server_adjust_buffer(key_memtype_id, key_maptype_id, 1, H5P_DEFAULT, key.buf_size, &key.buf, &is_vl_data, &key_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed"); + HGOTO_ERROR_FF(FAIL, "data type conversion failed"); kv.key = key.buf; kv.key_len = key_size; @@ -1010,10 +1010,10 @@ H5VL_iod_server_map_delete_cb(AXE_engine_t UNUSED axe_engine, kvs.ret = &ret; if(iod_kv_unlink_keys(iod_oh, wtid, NULL, 1, &kvs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); if(ret < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDEC, FAIL, "Unable to unlink KV pair"); + HGOTO_ERROR_FF(FAIL, "Unable to unlink KV pair"); done: #if H5_EFF_DEBUG @@ -1021,7 +1021,7 @@ done: #endif if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) - HDONE_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't send result of map delete"); + HDONE_ERROR_FF(FAIL, "can't send result of map delete"); input = (map_op_in_t *)H5MM_xfree(input); op_data = (op_data_t *)H5MM_xfree(op_data); @@ -1029,7 +1029,7 @@ done: /* close the map if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(iod_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HGOTO_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_map_delete_cb() */ @@ -1065,9 +1065,9 @@ H5VL_iod_server_map_close_cb(AXE_engine_t UNUSED axe_engine, #endif if((iod_obj_close(iod_oh.rd_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if((iod_obj_close(iod_oh.wr_oh, NULL, NULL)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); done: #if H5_EFF_DEBUG diff --git a/src/H5VLiod_obj.c b/src/H5VLiod_obj.c index b073071..4b42bbe 100644 --- a/src/H5VLiod_obj.c +++ b/src/H5VLiod_obj.c @@ -58,9 +58,9 @@ H5VL_iod_server_object_open_by_token_cb(AXE_engine_t UNUSED axe_engine, #endif if (iod_obj_open_read(coh, obj_id, tid, NULL /*hints*/, &obj_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); if (iod_obj_open_write(coh, obj_id, tid, NULL /*hints*/, &obj_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); #if H5_EFF_DEBUG fprintf(stderr, "Done with object open by token, sending response to client\n"); @@ -121,71 +121,71 @@ H5VL_iod_server_object_open_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open object */ if(H5VL_iod_server_open_path(coh, input->loc_id, input->loc_oh, input->loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); if (iod_obj_open_write(coh, obj_id, rtid, NULL, &obj_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); if(obj_id != input->loc_id) { /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } else { /* open the metadata KV */ if (iod_obj_open_read(coh, input->loc_mdkv_id, rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_OBJECT_TYPE, H5VL_IOD_KEY_OBJ_TYPE, cs_scope, NULL, &output.obj_type) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); switch(output.obj_type) { case H5I_MAP: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve mcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve mcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_MAP_KEY_TYPE, cs_scope, NULL, &output.id1) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_MAP_VALUE_TYPE, cs_scope, NULL, &output.id2) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); break; case H5I_GROUP: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); output.id1 = FAIL; output.id2 = FAIL; break; case H5I_DATASET: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, cs_scope, NULL, &output.id1) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &output.id2) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); break; case H5I_DATATYPE: { @@ -202,21 +202,21 @@ H5VL_iod_server_object_open_cb(AXE_engine_t UNUSED axe_engine, if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); /* retrieve blob size metadata from scratch pad */ if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "datatype size lookup failed"); + HGOTO_ERROR_FF(FAIL, "datatype size lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate BLOB read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate BLOB read buffer"); /* create memory descriptor for writing */ mem_desc = (iod_mem_desc_t *)malloc(sizeof(iod_mem_desc_t) + @@ -235,7 +235,7 @@ H5VL_iod_server_object_open_cb(AXE_engine_t UNUSED axe_engine, /* read the serialized type value from the BLOB object */ if(iod_blob_read(obj_oh.rd_oh, rtid, NULL, mem_desc, file_desc, &blob_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to read BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to read BLOB object"); if(blob_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* calculate a checksum for the datatype */ @@ -243,12 +243,12 @@ H5VL_iod_server_object_open_cb(AXE_engine_t UNUSED axe_engine, /* Verify checksum against one given by IOD */ if(blob_cs != dt_cs) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "Data Corruption detected when reading datatype"); + HGOTO_ERROR_FF(FAIL, "Data Corruption detected when reading datatype"); } /* decode the datatype */ if((output.id1 = H5Tdecode(buf)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to decode datatype"); + HGOTO_ERROR_FF(FAIL, "unable to decode datatype"); output.id2 = FAIL; free(mem_desc); @@ -257,12 +257,12 @@ H5VL_iod_server_object_open_cb(AXE_engine_t UNUSED axe_engine, break; } default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Invalid object type"); + HGOTO_ERROR_FF(FAIL, "Invalid object type"); } /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); output.iod_id = obj_id; output.mdkv_id = sp[0]; @@ -342,56 +342,56 @@ H5VL_iod_server_object_copy_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open object */ if(H5VL_iod_server_open_path(coh, input->src_loc_id, input->src_loc_oh, input->src_loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* the traversal will retrieve the location where the objects needs to be copied to. The traversal will fail if an intermediate group does not exist. */ if(H5VL_iod_server_traverse(coh, input->dst_loc_id, input->dst_loc_oh, input->dst_loc_name, FALSE, rtid, &new_name, &dst_id, &dst_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't traverse path"); + HGOTO_ERROR_FF(FAIL, "can't traverse path"); /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_write(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_OBJECT_TYPE, H5VL_IOD_KEY_OBJ_TYPE, cs_scope, NULL, &obj_type) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); switch(obj_type) { case H5I_MAP: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve mcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve mcpl"); break; case H5I_GROUP: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve gcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve gcpl"); break; case H5I_DATASET: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, cs_scope, NULL, &output.type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &output.space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); break; case H5I_DATATYPE: { @@ -405,16 +405,16 @@ H5VL_iod_server_object_copy_cb(AXE_engine_t UNUSED axe_engine, /* retrieve blob size metadata from scratch pad */ if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "datatype size lookup failed"); + HGOTO_ERROR_FF(FAIL, "datatype size lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate BLOB read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate BLOB read buffer"); /* create memory descriptor for reading */ mem_desc.nfrag = 1; @@ -429,7 +429,7 @@ H5VL_iod_server_object_copy_cb(AXE_engine_t UNUSED axe_engine, /* read the serialized type value from the BLOB object */ if(iod_blob_read(obj_oh, rtid, NULL, &mem_desc, &file_desc, NULL, &blob_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to write BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to write BLOB object"); if(blob_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* calculate a checksum for the datatype */ @@ -437,17 +437,17 @@ H5VL_iod_server_object_copy_cb(AXE_engine_t UNUSED axe_engine, /* Verify checksum against one given by IOD */ if(blob_cs != dt_cs) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "Data Corruption detected when reading datatype"); + HGOTO_ERROR_FF(FAIL, "Data Corruption detected when reading datatype"); } /* decode the datatype */ if((output.type_id = H5Tdecode(buf)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to decode datatype"); + HGOTO_ERROR_FF(FAIL, "unable to decode datatype"); free(buf); } default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Invalid object type"); + HGOTO_ERROR_FF(FAIL, "Invalid object type"); } /* create new object as a copy of the source object */ @@ -455,16 +455,16 @@ H5VL_iod_server_object_copy_cb(AXE_engine_t UNUSED axe_engine, /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* close the object handle */ if(input->src_loc_oh.cookie != obj_oh.cookie && iod_obj_close(obj_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* Insert object in the destination path */ if(H5VL_iod_insert_new_link(dst_oh, wtid, new_name, H5L_TYPE_HARD, &obj_id, cs_scope, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't insert KV value"); + HGOTO_ERROR_FF(FAIL, "can't insert KV value"); /* close dst group if it is not the location we started the traversal into */ @@ -536,7 +536,7 @@ H5VL_iod_server_object_exists_cb(AXE_engine_t UNUSED axe_engine, /* close the object */ if(loc_oh.rd_oh.cookie != obj_oh.rd_oh.cookie && iod_obj_close(obj_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* set return to TRUE */ ret = TRUE; @@ -602,41 +602,41 @@ H5VL_iod_server_object_get_info_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open object */ if(H5VL_iod_server_open_path(coh, loc_id, loc_oh, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "object does not exist"); + HGOTO_ERROR_FF(FAIL, "object does not exist"); oinfo.addr = obj_id; if(obj_id != loc_id || input->loc_mdkv_id == IOD_OBJ_INVALID) { /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV */ if (iod_obj_open_read(coh, sp[0], rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); /* open the attribute KV */ if (iod_obj_open_read(coh, sp[1], rtid, NULL, &attrkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open ATTRKV"); + HGOTO_ERROR_FF(FAIL, "can't open ATTRKV"); } else { /* open the metadata KV */ if (iod_obj_open_read(coh, input->loc_mdkv_id, rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); /* open the attribute KV */ if (iod_obj_open_read(coh, input->loc_attrkv_id, rtid, NULL, &attrkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_OBJECT_TYPE, H5VL_IOD_KEY_OBJ_TYPE, cs_scope, NULL, &obj_type) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve object type"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve object type"); switch(obj_type) { case H5I_GROUP: @@ -652,32 +652,32 @@ H5VL_iod_server_object_get_info_cb(AXE_engine_t UNUSED axe_engine, oinfo.type = H5O_TYPE_MAP; break; default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, + HGOTO_ERROR_FF(FAIL, "unsupported object type for H5Oget_info"); } if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_LINK_COUNT, H5VL_IOD_KEY_OBJ_LINK_COUNT, cs_scope, NULL, &link_count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); oinfo.rc = (unsigned) link_count; if(iod_kv_get_num(attrkv_oh, rtid, &num_attrs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve attribute count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve attribute count"); oinfo.num_attrs = (hsize_t)num_attrs; /* close the metadata KV */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* close the attribute KV */ if(iod_obj_close(attrkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(loc_oh.rd_oh.cookie != obj_oh.rd_oh.cookie && iod_obj_close(obj_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); #if H5_EFF_DEBUG fprintf(stderr, "Done with Object get_info, sending response to client\n"); @@ -744,27 +744,27 @@ H5VL_iod_server_object_set_comment_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open object */ if(H5VL_iod_server_open_path(coh, loc_id, loc_oh, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); if(loc_id != obj_id || input->loc_mdkv_id == IOD_OBJ_INVALID) { /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if (iod_obj_open_write(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } else { /* open the metadata KV */ if (iod_obj_open_write(coh, input->loc_mdkv_id, rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } { @@ -781,22 +781,22 @@ H5VL_iod_server_object_set_comment_cb(AXE_engine_t UNUSED axe_engine, cs[0] = H5_checksum_crc64(kv.key, kv.key_len); cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(mdkv_oh, wtid, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set comment in MDKV"); + HGOTO_ERROR_FF(FAIL, "can't set comment in MDKV"); } } /* close metadata KV and object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(loc_oh.rd_oh.cookie != obj_oh.rd_oh.cookie && iod_obj_close(obj_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); done: @@ -860,27 +860,27 @@ H5VL_iod_server_object_get_comment_cb(AXE_engine_t UNUSED axe_engine, /* Traverse Path and open object */ if(H5VL_iod_server_open_path(coh, loc_id, loc_oh, loc_name, rtid, cs_scope, &obj_id, &obj_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); if(loc_id != obj_id || input->loc_mdkv_id == IOD_OBJ_INVALID) { /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } else { /* open the metadata KV */ if (iod_obj_open_read(coh, input->loc_mdkv_id, rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); } comment.value_size = (ssize_t *)malloc(sizeof(ssize_t)); @@ -895,24 +895,24 @@ H5VL_iod_server_object_get_comment_cb(AXE_engine_t UNUSED axe_engine, if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_OBJ_COMMENT, key_size, NULL, &val_size, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "comment size lookup failed"); + HGOTO_ERROR_FF(FAIL, "comment size lookup failed"); if(NULL == (value = malloc ((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_OBJ_COMMENT, key_size, value, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "comment value lookup failed"); + HGOTO_ERROR_FF(FAIL, "comment value lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_OBJ_COMMENT, key_size, value, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } if(length) { if(NULL == (comment.value = (char *)malloc (length))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); memcpy(comment.value, value, length); } @@ -920,11 +920,11 @@ H5VL_iod_server_object_get_comment_cb(AXE_engine_t UNUSED axe_engine, /* close metadata KV and object */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); if(loc_oh.rd_oh.cookie != obj_oh.rd_oh.cookie && iod_obj_close(obj_oh.rd_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); *comment.value_size = (ssize_t)val_size; @@ -997,72 +997,72 @@ H5VL_iod_server_object_open_by_addr_cb(AXE_engine_t UNUSED axe_engine, #endif if (iod_obj_open_read(coh, obj_id, rtid, NULL, &obj_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't opeb obejct for read"); + HGOTO_ERROR_FF(FAIL, "can't opeb obejct for read"); if (iod_obj_open_write(coh, obj_id, rtid, NULL, &obj_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open object for write"); + HGOTO_ERROR_FF(FAIL, "can't open object for write"); /* get scratch pad of the object */ if(iod_obj_get_scratch(obj_oh.rd_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_OBJECT_TYPE, H5VL_IOD_KEY_OBJ_TYPE, cs_scope, NULL, &output.obj_type) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); switch(output.obj_type) { case H5I_MAP: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve mcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve mcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_MAP_KEY_TYPE, cs_scope, NULL, &output.id1) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_MAP_VALUE_TYPE, cs_scope, NULL, &output.id2) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); break; case H5I_GROUP: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); output.id1 = FAIL; output.id2 = FAIL; break; case H5I_DATASET: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, cs_scope, NULL, &output.id1) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &output.id2) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); break; case H5I_ATTR: if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, cs_scope, NULL, &output.id1) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, cs_scope, NULL, &output.id2) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); break; case H5I_DATATYPE: { @@ -1079,21 +1079,21 @@ H5VL_iod_server_object_open_by_addr_cb(AXE_engine_t UNUSED axe_engine, if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &output.cpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); /* retrieve blob size metadata from scratch pad */ if(iod_kv_get_value(mdkv_oh, rtid, H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, &val_size, iod_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "datatype size lookup failed"); + HGOTO_ERROR_FF(FAIL, "datatype size lookup failed"); if(cs_scope & H5_CHECKSUM_IOD) { if(H5VL_iod_verify_kv_pair(H5VL_IOD_KEY_DTYPE_SIZE, key_size, &buf_size, val_size, iod_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate BLOB read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate BLOB read buffer"); /* create memory descriptor for writing */ mem_desc = (iod_mem_desc_t *)malloc(sizeof(iod_mem_desc_t) + @@ -1112,7 +1112,7 @@ H5VL_iod_server_object_open_by_addr_cb(AXE_engine_t UNUSED axe_engine, /* read the serialized type value from the BLOB object */ if(iod_blob_read(obj_oh.rd_oh, rtid, NULL, mem_desc, file_desc, &blob_cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to read BLOB object"); + HGOTO_ERROR_FF(FAIL, "unable to read BLOB object"); if(blob_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* calculate a checksum for the datatype */ @@ -1120,12 +1120,12 @@ H5VL_iod_server_object_open_by_addr_cb(AXE_engine_t UNUSED axe_engine, /* Verify checksum against one given by IOD */ if(blob_cs != dt_cs) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "Data Corruption detected when reading datatype"); + HGOTO_ERROR_FF(FAIL, "Data Corruption detected when reading datatype"); } /* decode the datatype */ if((output.id1 = H5Tdecode(buf)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to decode datatype"); + HGOTO_ERROR_FF(FAIL, "unable to decode datatype"); output.id2 = FAIL; free(mem_desc); @@ -1134,12 +1134,12 @@ H5VL_iod_server_object_open_by_addr_cb(AXE_engine_t UNUSED axe_engine, break; } default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Invalid object type"); + HGOTO_ERROR_FF(FAIL, "Invalid object type"); } /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); output.iod_id = obj_id; output.mdkv_id = sp[0]; diff --git a/src/H5VLiod_server.c b/src/H5VLiod_server.c index 7215223..2360101 100644 --- a/src/H5VLiod_server.c +++ b/src/H5VLiod_server.c @@ -389,7 +389,7 @@ H5VL__iod_server_finish_axe_tasks(AXE_engine_t axe_engine, AXE_task_t start_rang for(u=start_range ; u<count+start_range ; u++) { if(AXE_SUCCEED != AXEfinish(axe_engine, u)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE task") + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE task") } done: @@ -419,11 +419,11 @@ H5VL_iod_server_eff_init(hg_handle_t handle) /* get the input from the client connecting */ if(HG_FAIL == HG_Handler_get_input(handle, &num_procs)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); /* initialize the IOD library */ if(iod_initialize(iod_comm, NULL, num_procs, num_procs) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't initialize"); + HGOTO_ERROR_FF(FAIL, "can't initialize"); /* set the root ID */ IOD_OBJID_SETOWNER_APP(ROOT_ID) @@ -459,7 +459,7 @@ H5VL_iod_server_eff_finalize(hg_handle_t handle) terminate_requests ++; if(iod_finalize(NULL) < 0 ) - HGOTO_ERROR2(H5E_FILE, H5E_CANTDEC, HG_FAIL, "can't finalize IOD"); + HGOTO_ERROR_FF(FAIL, "can't finalize IOD"); /* if all the peers that connected at the beginning have sent the terminate request, then finalize IOD and indicate that it is @@ -496,31 +496,31 @@ H5VL_iod_server_analysis_execute(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (analysis_execute_in_t *)H5MM_malloc(sizeof(analysis_execute_in_t)))) - HGOTO_ERROR2(H5E_FILE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); //if(AXE_SUCCEED != AXEgenerate_task_id(engine, &axe_id)) - //HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to generate ID for AXE task"); + //HGOTO_ERROR_FF(FAIL, "Unable to generate ID for AXE task"); op_data->hg_handle = handle; op_data->input = (void *)input; if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, 0, NULL, 0, NULL, H5VL_iod_server_analysis_execute_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -550,19 +550,19 @@ H5VL_iod_server_analysis_farm(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (analysis_farm_in_t *)H5MM_malloc(sizeof(analysis_farm_in_t)))) - HGOTO_ERROR2(H5E_FILE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(AXE_SUCCEED != AXEgenerate_task_id(engine, &axe_id)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to generate ID for AXE task"); + HGOTO_ERROR_FF(FAIL, "Unable to generate ID for AXE task"); op_data->hg_handle = handle; op_data->axe_id = axe_id; @@ -570,7 +570,7 @@ H5VL_iod_server_analysis_farm(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, axe_id, 0, NULL, 0, NULL, H5VL_iod_server_analysis_farm_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -600,26 +600,26 @@ H5VL_iod_server_analysis_transfer(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (AXE_task_t *)H5MM_malloc(sizeof(AXE_task_t)))) - HGOTO_ERROR2(H5E_FILE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); op_data->hg_handle = handle; op_data->input = (void *)input; if(AXE_SUCCEED != AXEgenerate_task_id(engine, &axe_id)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to generate ID for AXE task"); + HGOTO_ERROR_FF(FAIL, "Unable to generate ID for AXE task"); if (AXE_SUCCEED != AXEcreate_task(engine, axe_id, 0, NULL, 0, NULL, H5VL_iod_server_analysis_transfer_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -633,12 +633,12 @@ H5VL_iod_server_container_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(HG_FAIL == HG_Handler_get_input(handle, &file_name)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); /* open the container */ printf("Calling iod_container_open on %s\n", file_name); if(iod_container_open(file_name, NULL, IOD_CONT_R, &coh, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open file"); + HGOTO_ERROR_FF(FAIL, "can't open file"); HG_Handler_start_output(handle, &coh); @@ -657,11 +657,11 @@ H5VL_iod_server_container_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(HG_FAIL == HG_Handler_get_input(handle, &coh)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); /* open the container */ if(iod_container_close(coh, NULL, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open file"); + HGOTO_ERROR_FF(FAIL, "can't open file"); done: HG_Handler_start_output(handle, &ret_value); @@ -692,11 +692,11 @@ H5VL_iod_server_cancel_op(hg_handle_t handle) int ret_value = HG_SUCCESS; if(HG_FAIL == HG_Handler_get_input(handle, &axe_id)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); /* Try to remove the task. */ if(AXEremove(engine, axe_id, &remove_status) != AXE_SUCCEED) - HGOTO_ERROR2(H5E_SYM, H5E_CANTREMOVE, HG_FAIL, "can't remove AXE task; it has children"); + HGOTO_ERROR_FF(FAIL, "can't remove AXE task; it has children"); if(remove_status == AXE_CANCELED) HGOTO_DONE(H5VL_IOD_CANCELLED) @@ -707,7 +707,7 @@ H5VL_iod_server_cancel_op(hg_handle_t handle) fprintf(stderr, "Task is running. Attempting to cancel Manually\n"); if(AXEget_op_data(engine, axe_id, &op_data) != AXE_SUCCEED) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get op data"); + HGOTO_ERROR_FF(FAIL, "can't get op data"); /* Attempt to cancel the task manually */ } @@ -739,28 +739,28 @@ H5VL_iod_server_file_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (file_create_in_t *)H5MM_malloc(sizeof(file_create_in_t)))) - HGOTO_ERROR2(H5E_FILE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, 0, NULL, 0, NULL, H5VL_iod_server_file_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -789,28 +789,28 @@ H5VL_iod_server_file_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (file_open_in_t *) H5MM_malloc(sizeof(file_open_in_t)))) - HGOTO_ERROR2(H5E_FILE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, 0, NULL, 0, NULL, H5VL_iod_server_file_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -839,29 +839,29 @@ H5VL_iod_server_file_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (file_close_in_t *) H5MM_malloc(sizeof(file_close_in_t)))) - HGOTO_ERROR2(H5E_FILE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; if (AXE_SUCCEED != AXEcreate_barrier_task(engine, input->axe_info.axe_id, H5VL_iod_server_file_close_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -890,22 +890,22 @@ H5VL_iod_server_attr_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_create_in_t *) H5MM_malloc(sizeof(attr_create_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -913,7 +913,7 @@ H5VL_iod_server_attr_create(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -942,22 +942,22 @@ H5VL_iod_server_attr_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_open_in_t *) H5MM_malloc(sizeof(attr_open_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -965,7 +965,7 @@ H5VL_iod_server_attr_open(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -994,22 +994,22 @@ H5VL_iod_server_attr_read(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_io_in_t *) H5MM_malloc(sizeof(attr_io_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1017,7 +1017,7 @@ H5VL_iod_server_attr_read(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_read_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1046,22 +1046,22 @@ H5VL_iod_server_attr_write(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_io_in_t *) H5MM_malloc(sizeof(attr_io_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1069,7 +1069,7 @@ H5VL_iod_server_attr_write(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_write_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1098,22 +1098,22 @@ H5VL_iod_server_attr_exists(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_op_in_t *) H5MM_malloc(sizeof(attr_op_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1121,7 +1121,7 @@ H5VL_iod_server_attr_exists(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_exists_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1150,22 +1150,22 @@ H5VL_iod_server_attr_rename(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_rename_in_t *) H5MM_malloc(sizeof(attr_rename_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1173,7 +1173,7 @@ H5VL_iod_server_attr_rename(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_rename_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1202,22 +1202,22 @@ H5VL_iod_server_attr_remove(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_op_in_t *) H5MM_malloc(sizeof(attr_op_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1225,7 +1225,7 @@ H5VL_iod_server_attr_remove(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_remove_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1254,22 +1254,22 @@ H5VL_iod_server_attr_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (attr_close_in_t *) H5MM_malloc(sizeof(attr_close_in_t)))) - HGOTO_ERROR2(H5E_ATTR, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_ATTR, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1277,7 +1277,7 @@ H5VL_iod_server_attr_close(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_attr_close_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1306,21 +1306,21 @@ H5VL_iod_server_group_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (group_create_in_t *)H5MM_malloc(sizeof(group_create_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1328,7 +1328,7 @@ H5VL_iod_server_group_create(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_group_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1357,21 +1357,21 @@ H5VL_iod_server_group_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (group_open_in_t *)H5MM_malloc(sizeof(group_open_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1379,7 +1379,7 @@ H5VL_iod_server_group_open(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_group_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1408,21 +1408,21 @@ H5VL_iod_server_group_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (group_close_in_t *)H5MM_malloc(sizeof(group_close_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1430,7 +1430,7 @@ H5VL_iod_server_group_close(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_group_close_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; } /* end H5VL_iod_server_group_close() */ @@ -1458,22 +1458,22 @@ H5VL_iod_server_dset_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_create_in_t *) H5MM_malloc(sizeof(dset_create_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1481,7 +1481,7 @@ H5VL_iod_server_dset_create(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1510,22 +1510,22 @@ H5VL_iod_server_dset_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_open_in_t *) H5MM_malloc(sizeof(dset_open_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1533,7 +1533,7 @@ H5VL_iod_server_dset_open(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1562,22 +1562,22 @@ H5VL_iod_server_dset_read(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_io_in_t *) H5MM_malloc(sizeof(dset_io_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1585,7 +1585,7 @@ H5VL_iod_server_dset_read(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_read_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1614,22 +1614,22 @@ H5VL_iod_server_dset_get_vl_size(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_io_in_t *) H5MM_malloc(sizeof(dset_io_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1637,7 +1637,7 @@ H5VL_iod_server_dset_get_vl_size(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_get_vl_size_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1666,22 +1666,22 @@ H5VL_iod_server_dset_write(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_io_in_t *) H5MM_malloc(sizeof(dset_io_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1689,7 +1689,7 @@ H5VL_iod_server_dset_write(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_write_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1718,22 +1718,22 @@ H5VL_iod_server_dset_set_extent(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_set_extent_in_t *) H5MM_malloc(sizeof(dset_set_extent_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1741,7 +1741,7 @@ H5VL_iod_server_dset_set_extent(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_set_extent_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1770,22 +1770,22 @@ H5VL_iod_server_dset_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_close_in_t *) H5MM_malloc(sizeof(dset_close_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1793,7 +1793,7 @@ H5VL_iod_server_dset_close(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_close_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1823,22 +1823,22 @@ H5VL_iod_server_dset_set_index_info(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_set_index_info_in_t *) H5MM_malloc(sizeof(dset_set_index_info_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1846,7 +1846,7 @@ H5VL_iod_server_dset_set_index_info(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_set_index_info_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1875,22 +1875,22 @@ H5VL_iod_server_dset_get_index_info(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_get_index_info_in_t *) H5MM_malloc(sizeof(dset_get_index_info_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1898,7 +1898,7 @@ H5VL_iod_server_dset_get_index_info(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_get_index_info_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1927,22 +1927,22 @@ H5VL_iod_server_dset_remove_index_info(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dset_rm_index_info_in_t *) H5MM_malloc(sizeof(dset_rm_index_info_in_t)))) - HGOTO_ERROR2(H5E_DATASET, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATASET, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -1950,7 +1950,7 @@ H5VL_iod_server_dset_remove_index_info(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dset_remove_index_info_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -1980,22 +1980,22 @@ H5VL_iod_server_dtype_commit(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dtype_commit_in_t *) H5MM_malloc(sizeof(dtype_commit_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2003,7 +2003,7 @@ H5VL_iod_server_dtype_commit(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dtype_commit_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2032,22 +2032,22 @@ H5VL_iod_server_dtype_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dtype_open_in_t *) H5MM_malloc(sizeof(dtype_open_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2055,7 +2055,7 @@ H5VL_iod_server_dtype_open(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dtype_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2084,22 +2084,22 @@ H5VL_iod_server_dtype_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (dtype_close_in_t *) H5MM_malloc(sizeof(dtype_close_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2107,7 +2107,7 @@ H5VL_iod_server_dtype_close(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_dtype_close_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2136,22 +2136,22 @@ H5VL_iod_server_link_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_create_in_t *) H5MM_malloc(sizeof(link_create_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2159,7 +2159,7 @@ H5VL_iod_server_link_create(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_link_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2188,22 +2188,22 @@ H5VL_iod_server_link_move(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_move_in_t *) H5MM_malloc(sizeof(link_move_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2211,7 +2211,7 @@ H5VL_iod_server_link_move(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_link_move_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2240,22 +2240,22 @@ H5VL_iod_server_link_iterate(hg_handle_t UNUSED handle) #if 0 if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_iterate_in_t *) H5MM_malloc(sizeof(link_iterate_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2288,22 +2288,22 @@ H5VL_iod_server_link_exists(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_op_in_t *) H5MM_malloc(sizeof(link_op_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2311,7 +2311,7 @@ H5VL_iod_server_link_exists(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_link_exists_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2340,22 +2340,22 @@ H5VL_iod_server_link_get_info(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_op_in_t *) H5MM_malloc(sizeof(link_op_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2363,7 +2363,7 @@ H5VL_iod_server_link_get_info(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_link_get_info_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2392,22 +2392,22 @@ H5VL_iod_server_link_get_val(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_get_val_in_t *) H5MM_malloc(sizeof(link_get_val_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2415,7 +2415,7 @@ H5VL_iod_server_link_get_val(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_link_get_val_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2444,22 +2444,22 @@ H5VL_iod_server_link_remove(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (link_op_in_t *) H5MM_malloc(sizeof(link_op_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2467,7 +2467,7 @@ H5VL_iod_server_link_remove(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_link_remove_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2496,22 +2496,22 @@ H5VL_iod_server_object_open_by_token(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_token_in_t *) H5MM_malloc(sizeof(object_token_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2519,7 +2519,7 @@ H5VL_iod_server_object_open_by_token(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_open_by_token_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2548,22 +2548,22 @@ H5VL_iod_server_object_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_op_in_t *) H5MM_malloc(sizeof(object_op_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2571,7 +2571,7 @@ H5VL_iod_server_object_open(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2600,22 +2600,22 @@ H5VL_iod_server_object_copy(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_copy_in_t *) H5MM_malloc(sizeof(object_copy_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2623,7 +2623,7 @@ H5VL_iod_server_object_copy(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_copy_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2677,22 +2677,22 @@ H5VL_iod_server_object_exists(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_op_in_t *) H5MM_malloc(sizeof(object_op_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2700,7 +2700,7 @@ H5VL_iod_server_object_exists(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_exists_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2729,22 +2729,22 @@ H5VL_iod_server_object_set_comment(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_set_comment_in_t *) H5MM_malloc(sizeof(object_set_comment_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2752,7 +2752,7 @@ H5VL_iod_server_object_set_comment(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_set_comment_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2781,22 +2781,22 @@ H5VL_iod_server_object_get_comment(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_get_comment_in_t *) H5MM_malloc(sizeof(object_get_comment_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2804,7 +2804,7 @@ H5VL_iod_server_object_get_comment(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_get_comment_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2833,22 +2833,22 @@ H5VL_iod_server_object_get_info(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (object_op_in_t *) H5MM_malloc(sizeof(object_op_in_t)))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_NOSPACE, HG_FAIL, "can't allocate input struct for decoding"); + HGOTO_ERROR_FF(FAIL, "can't allocate input struct for decoding"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2856,7 +2856,7 @@ H5VL_iod_server_object_get_info(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_object_get_info_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2885,21 +2885,21 @@ H5VL_iod_server_map_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_create_in_t *)H5MM_malloc(sizeof(map_create_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2907,7 +2907,7 @@ H5VL_iod_server_map_create(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2936,21 +2936,21 @@ H5VL_iod_server_map_open(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_open_in_t *)H5MM_malloc(sizeof(map_open_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -2958,7 +2958,7 @@ H5VL_iod_server_map_open(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_open_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -2987,21 +2987,21 @@ H5VL_iod_server_map_set(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_set_in_t *)H5MM_malloc(sizeof(map_set_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3009,7 +3009,7 @@ H5VL_iod_server_map_set(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_set_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3038,21 +3038,21 @@ H5VL_iod_server_map_get(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_get_in_t *)H5MM_malloc(sizeof(map_get_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3060,7 +3060,7 @@ H5VL_iod_server_map_get(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_get_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3089,21 +3089,21 @@ H5VL_iod_server_map_get_count(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_get_count_in_t *)H5MM_malloc(sizeof(map_get_count_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3111,7 +3111,7 @@ H5VL_iod_server_map_get_count(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_get_count_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3140,21 +3140,21 @@ H5VL_iod_server_map_exists(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_op_in_t *)H5MM_malloc(sizeof(map_op_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3162,7 +3162,7 @@ H5VL_iod_server_map_exists(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_exists_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3191,21 +3191,21 @@ H5VL_iod_server_map_delete(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_op_in_t *)H5MM_malloc(sizeof(map_op_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3213,7 +3213,7 @@ H5VL_iod_server_map_delete(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_delete_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3242,21 +3242,21 @@ H5VL_iod_server_map_close(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (map_close_in_t *)H5MM_malloc(sizeof(map_close_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3264,7 +3264,7 @@ H5VL_iod_server_map_close(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_map_close_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3293,21 +3293,21 @@ H5VL_iod_server_rcxt_acquire(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (rc_acquire_in_t *)H5MM_malloc(sizeof(rc_acquire_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3315,7 +3315,7 @@ H5VL_iod_server_rcxt_acquire(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_rcxt_acquire_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3344,21 +3344,21 @@ H5VL_iod_server_rcxt_release(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (rc_release_in_t *)H5MM_malloc(sizeof(rc_release_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3366,7 +3366,7 @@ H5VL_iod_server_rcxt_release(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_rcxt_release_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3395,21 +3395,21 @@ H5VL_iod_server_rcxt_persist(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (rc_persist_in_t *)H5MM_malloc(sizeof(rc_persist_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3417,7 +3417,7 @@ H5VL_iod_server_rcxt_persist(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_rcxt_persist_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3446,21 +3446,21 @@ H5VL_iod_server_rcxt_snapshot(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (rc_snapshot_in_t *)H5MM_malloc(sizeof(rc_snapshot_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3468,7 +3468,7 @@ H5VL_iod_server_rcxt_snapshot(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_rcxt_snapshot_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3497,21 +3497,21 @@ H5VL_iod_server_trans_start(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (tr_start_in_t *)H5MM_malloc(sizeof(tr_start_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3519,7 +3519,7 @@ H5VL_iod_server_trans_start(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_trans_start_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3548,21 +3548,21 @@ H5VL_iod_server_trans_finish(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (tr_finish_in_t *)H5MM_malloc(sizeof(tr_finish_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3570,7 +3570,7 @@ H5VL_iod_server_trans_finish(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_trans_finish_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3599,21 +3599,21 @@ H5VL_iod_server_trans_set_dependency(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (tr_set_depend_in_t *)H5MM_malloc(sizeof(tr_set_depend_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3621,7 +3621,7 @@ H5VL_iod_server_trans_set_dependency(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_trans_set_dependency_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3650,21 +3650,21 @@ H5VL_iod_server_trans_skip(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (tr_skip_in_t *)H5MM_malloc(sizeof(tr_skip_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3672,7 +3672,7 @@ H5VL_iod_server_trans_skip(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_trans_skip_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3701,21 +3701,21 @@ H5VL_iod_server_trans_abort(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (tr_abort_in_t *)H5MM_malloc(sizeof(tr_abort_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3723,7 +3723,7 @@ H5VL_iod_server_trans_abort(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_trans_abort_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3752,21 +3752,21 @@ H5VL_iod_server_prefetch(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (prefetch_in_t *)H5MM_malloc(sizeof(prefetch_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3774,7 +3774,7 @@ H5VL_iod_server_prefetch(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_prefetch_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3803,21 +3803,21 @@ H5VL_iod_server_evict(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (evict_in_t *)H5MM_malloc(sizeof(evict_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3825,7 +3825,7 @@ H5VL_iod_server_evict(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_evict_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; @@ -3854,21 +3854,21 @@ H5VL_iod_server_view_create(hg_handle_t handle) int ret_value = HG_SUCCESS; if(NULL == (op_data = (op_data_t *)H5MM_malloc(sizeof(op_data_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(NULL == (input = (view_create_in_t *)H5MM_malloc(sizeof(view_create_in_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate axe op_data struct"); + HGOTO_ERROR_FF(FAIL, "can't allocate axe op_data struct"); if(HG_FAIL == HG_Handler_get_input(handle, input)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, HG_FAIL, "can't get input parameters"); + HGOTO_ERROR_FF(FAIL, "can't get input parameters"); if(NULL == engine) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "AXE engine not started"); + HGOTO_ERROR_FF(FAIL, "AXE engine not started"); if(input->axe_info.count && H5VL__iod_server_finish_axe_tasks(engine, input->axe_info.start_range, input->axe_info.count) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "Unable to cleanup AXE tasks"); + HGOTO_ERROR_FF(FAIL, "Unable to cleanup AXE tasks"); op_data->hg_handle = handle; op_data->input = (void *)input; @@ -3876,7 +3876,7 @@ H5VL_iod_server_view_create(hg_handle_t handle) if (AXE_SUCCEED != AXEcreate_task(engine, input->axe_info.axe_id, input->axe_info.num_parents, input->axe_info.parent_axe_ids, 0, NULL, H5VL_iod_server_view_create_cb, op_data, NULL)) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, HG_FAIL, "can't insert task into async engine"); + HGOTO_ERROR_FF(FAIL, "can't insert task into async engine"); done: return ret_value; diff --git a/src/H5VLiod_server.h b/src/H5VLiod_server.h index 683f793..347828d 100644 --- a/src/H5VLiod_server.h +++ b/src/H5VLiod_server.h @@ -45,17 +45,18 @@ #define H5VL_IOD_IDX_PLUGIN_ID "index_plugin_id" #define H5VL_IOD_IDX_PLUGIN_MD "index_plugin_metadata" -#define HGOTO_ERROR2(maj, min, ret_val, string) { \ + +#define HGOTO_ERROR_FF(ret_val, string) { \ fprintf(stderr, "%s\n", string); \ - HGOTO_DONE2(ret_val) \ + HGOTO_DONE_FF(ret_val) \ } -#define HDONE_ERROR2(maj, min, ret_val, string) { \ +#define HDONE_ERROR_FF(ret_val, string) { \ fprintf(stderr, "%s\n", string); \ ret_value = ret_val; \ } -#define HGOTO_DONE2(ret_val) {ret_value = ret_val; goto done;} +#define HGOTO_DONE_FF(ret_val) {ret_value = ret_val; goto done;} /* Enum for metadata types stored in MD KV for HDF5->IOD objects */ typedef enum H5VL_iod_metadata_t { diff --git a/src/H5VLiod_trans.c b/src/H5VLiod_trans.c index 9daf990..33f5590 100644 --- a/src/H5VLiod_trans.c +++ b/src/H5VLiod_trans.c @@ -67,7 +67,7 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, rcapl_id = input->rcapl_id; if(H5Pget_rcapl_version_request(rcapl_id, &acquire_req) < 0) { - HGOTO_ERROR2(H5E_PLIST, H5E_CANTSET,FAIL, "can't get acquire request property"); + HGOTO_ERROR_FF(FAIL, "can't get acquire request property"); } switch(acquire_req) { @@ -77,7 +77,7 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, #endif if((ret = iod_trans_start(coh, &c_version, NULL, 0, IOD_TRANS_R, NULL)) < 0) { fprintf(stderr, "can't acquire read context. %d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't acquire read context"); + HGOTO_ERROR_FF(FAIL, "can't acquire read context"); } acquired_version = c_version; break; @@ -87,7 +87,7 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, #endif c_version = IOD_TID_UNKNOWN; if(iod_trans_start(coh, &c_version, NULL, 0, IOD_TRANS_R, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't acquire read context"); + HGOTO_ERROR_FF(FAIL, "can't acquire read context"); acquired_version = c_version; break; case H5RC_NEXT: @@ -99,7 +99,7 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, fprintf(stderr, "Next Acquire Read Context %"PRIu64"\n", input->c_version); #endif if(iod_query_cont_trans_stat(coh, &tids, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get container tids status"); + HGOTO_ERROR_FF(FAIL, "can't get container tids status"); acquired_version = IOD_TID_UNKNOWN; @@ -111,12 +111,12 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, } if(IOD_TID_UNKNOWN == acquired_version) { - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, + HGOTO_ERROR_FF(FAIL, "can't get a read version"); } if(iod_free_cont_trans_stat(coh, tids) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free container transaction status object"); + HGOTO_ERROR_FF(FAIL, "can't free container transaction status object"); break; } case H5RC_PREV: @@ -128,12 +128,12 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, fprintf(stderr, "Next Acquire Read Context %"PRIu64"\n", input->c_version); #endif if(iod_query_cont_trans_stat(coh, &tids, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get container tids status"); + HGOTO_ERROR_FF(FAIL, "can't get container tids status"); if(c_version >= tids->latest_rdable) { acquired_version = tids->latest_rdable; if(iod_trans_start(coh, &acquired_version, NULL, 0, IOD_TRANS_R, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't acquire read context"); + HGOTO_ERROR_FF(FAIL, "can't acquire read context"); break; } @@ -148,17 +148,17 @@ H5VL_iod_server_rcxt_acquire_cb(AXE_engine_t UNUSED axe_engine, } if(IOD_TID_UNKNOWN == acquired_version) { - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, + HGOTO_ERROR_FF(FAIL, "can't get a read version"); } if(iod_free_cont_trans_stat(coh, tids) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't free container transaction status object"); + HGOTO_ERROR_FF(FAIL, "can't free container transaction status object"); break; } default: - HGOTO_ERROR2(H5E_PLIST, H5E_CANTSET, FAIL, "invalid acquire request"); + HGOTO_ERROR_FF(FAIL, "invalid acquire request"); } output.c_version = acquired_version; @@ -214,7 +214,7 @@ H5VL_iod_server_rcxt_release_cb(AXE_engine_t UNUSED axe_engine, #endif if(iod_trans_finish(coh, input->c_version, NULL, 0, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't release Read Context"); + HGOTO_ERROR_FF(FAIL, "can't release Read Context"); done: if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) @@ -294,7 +294,7 @@ H5VL_iod_server_rcxt_persist_cb(AXE_engine_t UNUSED axe_engine, } else if(-ESHUTDOWN == ret) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't persist read context"); + HGOTO_ERROR_FF(FAIL, "can't persist read context"); } else { fprintf(stderr, "Retry failed.. %d (%s).\n", ret, strerror(-ret)); @@ -305,7 +305,7 @@ H5VL_iod_server_rcxt_persist_cb(AXE_engine_t UNUSED axe_engine, } if(ret != 0) { - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't persist read context"); + HGOTO_ERROR_FF(FAIL, "can't persist read context"); } #if H5_HAVE_IOD_CORRUPT_TOOL @@ -365,7 +365,7 @@ H5VL_iod_server_rcxt_snapshot_cb(AXE_engine_t UNUSED axe_engine, /* MSC - can only snapshot latest version */ if(iod_container_snapshot(coh, tid, input->snapshot_name, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't snapshot Read Context"); + HGOTO_ERROR_FF(FAIL, "can't snapshot Read Context"); done: if(HG_SUCCESS != HG_Handler_start_output(op_data->hg_handle, &ret_value)) @@ -413,10 +413,10 @@ H5VL_iod_server_trans_start_cb(AXE_engine_t UNUSED axe_engine, trspl_id = input->trspl_id; if(H5Pget_trspl_num_peers(trspl_id, &num_peers) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't get acquire request property"); + HGOTO_ERROR_FF(FAIL, "can't get acquire request property"); if(iod_trans_start(coh, &trans_num, NULL, num_peers, IOD_TRANS_W, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't start transaction"); + HGOTO_ERROR_FF(FAIL, "can't start transaction"); #if H5_EFF_DEBUG fprintf(stderr, "Done with Transaction Start\n"); @@ -477,7 +477,7 @@ H5VL_iod_server_trans_finish_cb(AXE_engine_t UNUSED axe_engine, ret = iod_obj_open_write(coh, oidkv_id, trans_num, NULL, &oidkv_oh, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open oid KV"); + HGOTO_ERROR_FF(FAIL, "can't open oid KV"); step ++; @@ -492,22 +492,22 @@ H5VL_iod_server_trans_finish_cb(AXE_engine_t UNUSED axe_engine, cs[0] = H5_checksum_crc64(kv.key, kv.key_len); cs[1] = H5_checksum_crc64(kv.value, kv.value_len); if (iod_kv_set(oidkv_oh, trans_num, NULL, &kv, cs, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oidkv_oh, trans_num, NULL, &kv, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in oid KV"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in oid KV"); } if(iod_obj_close(oidkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object handle"); + HGOTO_ERROR_FF(FAIL, "can't close object handle"); step --; /* Finish the transaction */ if((ret = iod_trans_finish(coh, trans_num, NULL, 0, NULL)) < 0) { fprintf(stderr, "can't finish transaction %d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't finish transaction"); + HGOTO_ERROR_FF(FAIL, "can't finish transaction"); } #if H5_HAVE_IOD_CORRUPT_TOOL @@ -522,7 +522,7 @@ H5VL_iod_server_trans_finish_cb(AXE_engine_t UNUSED axe_engine, #endif if(iod_trans_start(coh, &trans_num, NULL, 0, IOD_TRANS_R, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't acquire read context"); + HGOTO_ERROR_FF(FAIL, "can't acquire read context"); } #if H5_EFF_DEBUG @@ -576,7 +576,7 @@ H5VL_iod_server_trans_set_dependency_cb(AXE_engine_t UNUSED axe_engine, /* MSC - set depends */ //if(iod_trans_depend(coh, depends, NULL) < 0) - //HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set dependency between transactions"); + //HGOTO_ERROR_FF(FAIL, "can't set dependency between transactions"); #if H5_EFF_DEBUG fprintf(stderr, "Done with Transaction Set_Dependency\n"); @@ -626,7 +626,7 @@ H5VL_iod_server_trans_skip_cb(AXE_engine_t UNUSED axe_engine, /* MSC - set skip ranges */ skip_ranges.n_range = 1; //if(iod_trans_skip(coh, skip_ranges, NULL) < 0) - //HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't skip transactions"); + //HGOTO_ERROR_FF(FAIL, "can't skip transactions"); #if H5_EFF_DEBUG fprintf(stderr, "Done with Transaction Skip\n"); @@ -677,7 +677,7 @@ H5VL_iod_server_trans_abort_cb(AXE_engine_t UNUSED axe_engine, fprintf(stderr, "Transaction %"PRIu64" already discarded\n", input->trans_num); else if(ret < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTSET, FAIL, "can't abort transaction"); + HGOTO_ERROR_FF(FAIL, "can't abort transaction"); } #if H5_EFF_DEBUG @@ -733,7 +733,7 @@ H5VL_iod_server_prefetch_cb(AXE_engine_t UNUSED axe_engine, ret = iod_obj_fetch(iod_oh.rd_oh, tid, NULL, NULL, NULL, &replica_id, NULL); if(ret != 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't prefetch object"); + HGOTO_ERROR_FF(FAIL, "can't prefetch object"); } #if H5_EFF_DEBUG @@ -797,7 +797,7 @@ H5VL_iod_server_evict_cb(AXE_engine_t UNUSED axe_engine, if(ret < 0) { fprintf(stderr, "%d (%s).\n", ret, strerror(-ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't evict object"); + HGOTO_ERROR_FF(FAIL, "can't evict object"); } #if H5_EFF_DEBUG diff --git a/src/H5VLiod_util.c b/src/H5VLiod_util.c index 01646ed..ea5cd7d 100644 --- a/src/H5VLiod_util.c +++ b/src/H5VLiod_util.c @@ -76,15 +76,15 @@ H5VL_iod_server_traverse(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t lo /* open the current group */ if(cur_oh.rd_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, loc_id, wtid, NULL, &cur_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); } /* Wrap the local buffer for serialized header info */ if(NULL == (wb = H5WB_wrap(comp_buf, sizeof(comp_buf)))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't wrap buffer") + HGOTO_ERROR_FF(FAIL, "can't wrap buffer") /* Get a pointer to a buffer that's large enough */ if(NULL == (comp = (char *)H5WB_actual(wb, (HDstrlen(path) + 1)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't get actual buffer") + HGOTO_ERROR_FF(FAIL, "can't get actual buffer") /* Traverse the path */ while((path = H5G__component(path, &nchars)) && *path) { @@ -119,7 +119,7 @@ H5VL_iod_server_traverse(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t lo /* lookup next object in the current group */ if(H5VL_iod_get_metadata(cur_oh.rd_oh, rtid, H5VL_IOD_LINK, comp, cs_scope, NULL, &value) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); /* if this a soft link, traverse the link value if the ID is undefined */ if(H5L_TYPE_SOFT == value.link_type) { @@ -130,7 +130,7 @@ H5VL_iod_server_traverse(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t lo /* Traverse Path and open the target object */ if(H5VL_iod_server_open_path(coh, cur_id, cur_oh, value.u.symbolic_name, rtid, cs_scope, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); free(value.u.symbolic_name); } @@ -140,12 +140,12 @@ H5VL_iod_server_traverse(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t lo /* Close previous read handle unless it is the original one */ if(loc_handle.rd_oh.cookie != prev_oh.cookie) { if(iod_obj_close(prev_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); } /* open the current group */ if (iod_obj_open_read(coh, cur_id, rtid, NULL, &cur_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); /* Advance to next component in string */ path += nchars; @@ -153,7 +153,7 @@ H5VL_iod_server_traverse(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t lo /* Release temporary component buffer */ if(wb && H5WB_unwrap(wb) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't release wrapped buffer"); + HGOTO_ERROR_FF(FAIL, "can't release wrapped buffer"); *iod_id = cur_id; (*iod_oh).rd_oh.cookie = cur_oh.rd_oh.cookie; @@ -162,7 +162,7 @@ H5VL_iod_server_traverse(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t lo loc_handle.wr_oh.cookie == IOD_OH_UNDEFINED) { /* open a write handle on the ID. */ if (iod_obj_open_write(coh, cur_id, wtid, NULL, &cur_oh.wr_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); } (*iod_oh).wr_oh.cookie = cur_oh.wr_oh.cookie; @@ -208,15 +208,15 @@ H5VL_iod_server_open_path(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t l if(cur_oh.rd_oh.cookie == IOD_OH_UNDEFINED) { /* open the current group */ if (iod_obj_open_read(coh, loc_id, rtid, NULL, &cur_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open start location"); + HGOTO_ERROR_FF(FAIL, "can't open start location"); } /* Wrap the local buffer for serialized header info */ if(NULL == (wb = H5WB_wrap(comp_buf, sizeof(comp_buf)))) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't wrap buffer") + HGOTO_ERROR_FF(FAIL, "can't wrap buffer") /* Get a pointer to a buffer that's large enough */ if(NULL == (comp = (char *)H5WB_actual(wb, (HDstrlen(path) + 1)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't get actual buffer") + HGOTO_ERROR_FF(FAIL, "can't get actual buffer") /* Traverse the path */ while((path = H5G__component(path, &nchars)) && *path) { @@ -245,8 +245,8 @@ H5VL_iod_server_open_path(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t l /* Close previous handle unless it is the original one */ if(loc_handle.rd_oh.cookie != prev_oh.cookie && iod_obj_close(prev_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); } /* if this a soft link, traverse the link value if the ID is undefined */ @@ -258,7 +258,7 @@ H5VL_iod_server_open_path(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t l /* Traverse Path and open the target object */ if(H5VL_iod_server_open_path(coh, cur_id, cur_oh, value.u.symbolic_name, rtid, cs_scope, &cur_id, &cur_oh) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); free(value.u.symbolic_name); } @@ -268,11 +268,11 @@ H5VL_iod_server_open_path(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t l /* Close previous handle unless it is the original one */ if(loc_handle.rd_oh.cookie != prev_oh.cookie && iod_obj_close(prev_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); /* open the current group */ if (iod_obj_open_read(coh, cur_id, rtid, NULL, &cur_oh.rd_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current object"); + HGOTO_ERROR_FF(FAIL, "can't open current object"); /* Advance to next component in string */ path += nchars; @@ -280,7 +280,7 @@ H5VL_iod_server_open_path(iod_handle_t coh, iod_obj_id_t loc_id, iod_handles_t l /* Release temporary component buffer */ if(wb && H5WB_unwrap(wb) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't release wrapped buffer"); + HGOTO_ERROR_FF(FAIL, "can't release wrapped buffer"); *iod_id = cur_id; (*iod_oh).rd_oh.cookie = cur_oh.rd_oh.cookie; @@ -313,13 +313,13 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) /* get the rank of this dataspace */ if((ndims = H5Sget_simple_extent_ndims(space_id)) < 0) - HGOTO_ERROR2(H5E_INTERNAL, H5E_CANTGET, FAIL, "unable to get dataspace dimesnsion"); + HGOTO_ERROR_FF(FAIL, "unable to get dataspace dimesnsion"); switch(H5Sget_select_type(space_id)) { case H5S_SEL_NONE: /* nothing selected */ num_descriptors = 0; - HGOTO_DONE2(SUCCEED); + HGOTO_DONE_FF(SUCCEED); case H5S_SEL_ALL: /* The entire dataspace is selected, 1 large iod hyperslab is needed */ num_descriptors = 1; @@ -329,7 +329,7 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) /* get the dimensions sizes of the dataspace */ if(H5Sget_simple_extent_dims(space_id, dims, NULL) < 0) - HGOTO_ERROR2(H5E_INTERNAL, H5E_CANTGET, FAIL, "unable to get dataspace dimesnsion sizes"); + HGOTO_ERROR_FF(FAIL, "unable to get dataspace dimesnsion sizes"); /* populate the hyperslab */ for(i=0 ; i<ndims ; i++) { hslabs[0].start[i] = 0; @@ -343,7 +343,7 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) { /* we need a hyperslab element for each point */ if((num_descriptors = H5Sget_select_elem_npoints(space_id)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "invalid point selection"); + HGOTO_ERROR_FF(FAIL, "invalid point selection"); if(NULL != hslabs) { hsize_t *points = NULL; @@ -352,11 +352,11 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) point_count = (hsize_t)num_descriptors * (unsigned int)ndims * sizeof(hsize_t); if(NULL == (points = (hsize_t *)malloc(point_count))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate array for points coords"); + HGOTO_ERROR_FF(FAIL, "can't allocate array for points coords"); if(H5Sget_select_elem_pointlist(space_id, (hsize_t)0, (hsize_t)num_descriptors, points) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "Failed to retrieve point coordinates"); + HGOTO_ERROR_FF(FAIL, "Failed to retrieve point coordinates"); /* populate the hyperslab */ for(n=0 ; n<num_descriptors ; n++) { @@ -390,7 +390,7 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) hslabs[0].stride, hslabs[0].count, hslabs[0].block) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "Failed to retrieve hyperslab selection"); + HGOTO_ERROR_FF(FAIL, "Failed to retrieve hyperslab selection"); for(i=0 ; i<ndims ; i++) { hslabs[0].stride[i] = hslabs[0].block[i] * hslabs[0].stride[i]; } @@ -399,7 +399,7 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) /* Otherwise populate the hslabs by getting every block */ else { if((num_descriptors = H5Sget_select_hyper_nblocks(space_id)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "invalid hyperslab selection"); + HGOTO_ERROR_FF(FAIL, "invalid hyperslab selection"); if(NULL != hslabs) { hsize_t *blocks = NULL; @@ -408,13 +408,13 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) block_count = (unsigned int)ndims * (hsize_t)num_descriptors * sizeof(hsize_t) * 2; if(NULL == (blocks = (hsize_t *)malloc(block_count))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate array for points coords"); + HGOTO_ERROR_FF(FAIL, "can't allocate array for points coords"); fprintf(stderr, "block count = %zu\n", block_count); if(H5Sget_select_hyper_blocklist(space_id, (hsize_t)0, (hsize_t)num_descriptors, blocks) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "Failed to retrieve point coordinates"); + HGOTO_ERROR_FF(FAIL, "Failed to retrieve point coordinates"); /* populate the hyperslab */ for(n=0 ; n<num_descriptors ; n++) { @@ -438,7 +438,7 @@ H5VL_iod_get_file_desc(hid_t space_id, hssize_t *count, iod_hyperslab_t *hslabs) case H5S_SEL_ERROR: case H5S_SEL_N: default: - HGOTO_ERROR2(H5E_ARGS, H5E_UNSUPPORTED, FAIL, "Invalid Selection type"); + HGOTO_ERROR_FF(FAIL, "Invalid Selection type"); } *count = num_descriptors; @@ -474,12 +474,12 @@ H5VL_iod_insert_plist(iod_handle_t oh, iod_trans_id_t tid, hid_t plist_id, /* determine the buffer size needed to store the encoded plist */ if(H5Pencode(plist_id, NULL, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode plist"); + HGOTO_ERROR_FF(FAIL, "failed to encode plist"); if(NULL == (value = malloc (buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate plist buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate plist buffer"); /* encode plist */ if(H5Pencode(plist_id, value, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode plist"); + HGOTO_ERROR_FF(FAIL, "failed to encode plist"); kv.key = (void *)key; kv.key_len = (iod_size_t)strlen(key); @@ -497,11 +497,11 @@ H5VL_iod_insert_plist(iod_handle_t oh, iod_trans_id_t tid, hid_t plist_id, #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -555,11 +555,11 @@ H5VL_iod_insert_link_count(iod_handle_t oh, iod_trans_id_t tid, uint64_t count, #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -608,11 +608,11 @@ H5VL_iod_insert_object_type(iod_handle_t oh, iod_trans_id_t tid, H5I_type_t obj_ #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -650,12 +650,12 @@ H5VL_iod_insert_datatype(iod_handle_t oh, iod_trans_id_t tid, hid_t type_id, /* determine the buffer size needed to store the encoded type */ if(H5Tencode(type_id, NULL, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode type"); + HGOTO_ERROR_FF(FAIL, "failed to encode type"); if(NULL == (value = malloc (buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate type buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate type buffer"); /* encode type */ if(H5Tencode(type_id, value, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode type"); + HGOTO_ERROR_FF(FAIL, "failed to encode type"); kv.key = (void *)key; kv.key_len = (iod_size_t)strlen(key); @@ -673,11 +673,11 @@ H5VL_iod_insert_datatype(iod_handle_t oh, iod_trans_id_t tid, hid_t type_id, #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -717,12 +717,12 @@ H5VL_iod_insert_datatype_with_key(iod_handle_t oh, iod_trans_id_t tid, hid_t typ /* determine the buffer size needed to store the encoded type */ if(H5Tencode(type_id, NULL, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode type"); + HGOTO_ERROR_FF(FAIL, "failed to encode type"); if(NULL == (value = malloc (buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate type buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate type buffer"); /* encode type */ if(H5Tencode(type_id, value, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode type"); + HGOTO_ERROR_FF(FAIL, "failed to encode type"); kv.key = (void *)key; kv.key_len = (iod_size_t)strlen(key); @@ -740,11 +740,11 @@ H5VL_iod_insert_datatype_with_key(iod_handle_t oh, iod_trans_id_t tid, hid_t typ #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -783,12 +783,12 @@ H5VL_iod_insert_dataspace(iod_handle_t oh, iod_trans_id_t tid, hid_t space_id, /* determine the buffer size needed to store the encoded space */ if(H5Sencode(space_id, NULL, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode space"); + HGOTO_ERROR_FF(FAIL, "failed to encode space"); if(NULL == (value = malloc (buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate space buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate space buffer"); /* encode space */ if(H5Sencode(space_id, value, &buf_size) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTENCODE, FAIL, "failed to encode space"); + HGOTO_ERROR_FF(FAIL, "failed to encode space"); kv.key = (void *)key; kv.key_len = (iod_size_t)strlen(key); @@ -806,11 +806,11 @@ H5VL_iod_insert_dataspace(iod_handle_t oh, iod_trans_id_t tid, hid_t space_id, #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -878,7 +878,7 @@ H5VL_iod_insert_new_link(iod_handle_t oh, iod_trans_id_t tid, const char *link_n case H5L_TYPE_EXTERNAL: case H5L_TYPE_MAX: default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unsupported link type"); + HGOTO_ERROR_FF(FAIL, "unsupported link type"); } kv.key = (void *)link_name; @@ -897,11 +897,11 @@ H5VL_iod_insert_new_link(iod_handle_t oh, iod_trans_id_t tid, const char *link_n #endif if (iod_kv_set(oh, tid, hints, &kv, cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } else { if (iod_kv_set(oh, tid, hints, &kv, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't set KV pair in parent"); + HGOTO_ERROR_FF(FAIL, "can't set KV pair in parent"); } done: @@ -944,16 +944,16 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m hid_t plist_id; if(iod_kv_get_value(oh, tid, key, key_size, NULL, &val_size, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if(NULL == (value = malloc((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(oh, tid, key, key_size, (char *)value, &val_size, iod_cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if((plist_id = H5Pdecode(value)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDECODE, FAIL, "failed to decode cpl"); + HGOTO_ERROR_FF(FAIL, "failed to decode cpl"); *((hid_t *)ret) = plist_id; break; @@ -961,10 +961,10 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m case H5VL_IOD_LINK_COUNT: val_size = sizeof(uint64_t); if(NULL == (value = malloc((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(oh, tid, key, key_size, (char *)value, &val_size, iod_cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "link_count lookup failed"); + HGOTO_ERROR_FF(FAIL, "link_count lookup failed"); memcpy(ret, value, val_size); break; @@ -973,16 +973,16 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m hid_t type_id; if(iod_kv_get_value(oh, tid, key, key_size, NULL, &val_size, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if(NULL == (value = malloc((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(oh, tid, key, key_size, (char *)value, &val_size, iod_cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if((type_id = H5Tdecode(value)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDECODE, FAIL, "failed to decode datatype"); + HGOTO_ERROR_FF(FAIL, "failed to decode datatype"); *((hid_t *)ret) = type_id; break; @@ -992,16 +992,16 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m hid_t space_id; if(iod_kv_get_value(oh, tid, key, key_size, NULL, &val_size, NULL, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if(NULL == (value = malloc((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(oh, tid, key, key_size, (char *)value, &val_size, iod_cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); if((space_id = H5Sdecode(value)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTDECODE, FAIL, "failed to decode dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to decode dataspace"); *((hid_t *)ret) = space_id; break; @@ -1009,10 +1009,10 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m case H5VL_IOD_OBJECT_TYPE: val_size = sizeof(int32_t); if(NULL == (value = malloc((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(oh, tid, key, key_size, (char *)value, &val_size, iod_cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "link_count lookup failed"); + HGOTO_ERROR_FF(FAIL, "link_count lookup failed"); memcpy(ret, value, val_size); break; @@ -1024,13 +1024,13 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m if((iod_ret = iod_kv_get_value(oh, tid, key, key_size, NULL, &val_size, NULL, event)) < 0) { fprintf(stderr, "%d (%s).\n", iod_ret, strerror(-iod_ret)); - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); } if(NULL == (value = malloc((size_t)val_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate value buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate value buffer"); if(iod_kv_get_value(oh, tid, key, key_size, (char *)value, &val_size, iod_cs, event) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "lookup failed"); + HGOTO_ERROR_FF(FAIL, "lookup failed"); val_ptr = (uint8_t *)value; @@ -1048,12 +1048,12 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m case H5L_TYPE_EXTERNAL: case H5L_TYPE_MAX: default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unsupported link type"); + HGOTO_ERROR_FF(FAIL, "unsupported link type"); } break; } default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "invalide metadata type"); + HGOTO_ERROR_FF(FAIL, "invalide metadata type"); } if(cs_scope & H5_CHECKSUM_IOD) { @@ -1067,7 +1067,7 @@ H5VL_iod_get_metadata(iod_handle_t oh, iod_trans_id_t tid, H5VL_iod_metadata_t m fprintf(stderr, "Value CS iod = %016lX computed = %016lX\n", iod_cs[1], cs[1]); #endif if(iod_cs[0] != cs[0] || iod_cs[1] != cs[1]) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected when reading metadata from IOD"); + HGOTO_ERROR_FF(FAIL, "Corruption detected when reading metadata from IOD"); } done: @@ -1139,7 +1139,7 @@ H5VL__iod_server_adjust_buffer(hid_t mem_type_id, hid_t dset_type_id, size_t nel buf_size = dset_type_size * nelmts; if(NULL == (*buf = realloc(*buf, (size_t)buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "Can't adjust buffer for DT conversion"); + HGOTO_ERROR_FF(FAIL, "Can't adjust buffer for DT conversion"); #if H5_EFF_DEBUG fprintf(stderr, "Adjusted Buffer size for dt conversion from %zu to %lld\n", size, buf_size); @@ -1148,7 +1148,7 @@ H5VL__iod_server_adjust_buffer(hid_t mem_type_id, hid_t dset_type_id, size_t nel else { buf_size = mem_type_size * nelmts; if(buf_size != size) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Incoming data size is not equal to expected size"); + HGOTO_ERROR_FF(FAIL, "Incoming data size is not equal to expected size"); } *_buf_size = buf_size; @@ -1160,7 +1160,7 @@ H5VL__iod_server_adjust_buffer(hid_t mem_type_id, hid_t dset_type_id, size_t nel *_buf_size = size; break; default: - HGOTO_ERROR2(H5E_ARGS, H5E_CANTINIT, FAIL, "unsupported datatype"); + HGOTO_ERROR_FF(FAIL, "unsupported datatype"); } done: @@ -1212,7 +1212,7 @@ H5VL_iod_verify_kv_pair(void *key, iod_size_t key_size, void *value, iod_size_t #endif if(iod_cs[0] != cs[0] && iod_cs[1] != cs[1]) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Corruption detected in IOD KV pair"); + HGOTO_ERROR_FF(FAIL, "Corruption detected in IOD KV pair"); done: return ret_value; @@ -1248,29 +1248,29 @@ H5VL__iod_get_h5_obj_type(iod_obj_id_t oid, iod_handle_t coh, iod_trans_id_t rti iod_checksum_t sp_cs = 0; if (iod_obj_open_read(coh, oid, rtid, NULL /*hints*/, &oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open object"); + HGOTO_ERROR_FF(FAIL, "can't open object"); /* get scratch pad of the object */ if(iod_obj_get_scratch(oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata KV */ if (iod_obj_open_read(coh, sp[0], rtid, NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open MDKV"); + HGOTO_ERROR_FF(FAIL, "can't open MDKV"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_OBJECT_TYPE, H5VL_IOD_KEY_OBJ_TYPE, cs_scope, NULL, &obj_type) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link count"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link count"); if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); if(iod_obj_close(oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); } ret_value = obj_type; @@ -1307,11 +1307,11 @@ H5VL_iod_server_iterate(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t rt /* Get the object ID and iterate into every member in the group */ if (iod_obj_open_read(coh, obj_id, rtid, NULL, &obj_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); ret = iod_kv_get_num(obj_oh, rtid, &num_entries, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get number of KV entries"); + HGOTO_ERROR_FF(FAIL, "can't get number of KV entries"); if(0 != num_entries) { iod_kv_params_t *kvs = NULL; @@ -1337,7 +1337,7 @@ H5VL_iod_server_iterate(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t rt ret = iod_kv_list_key(obj_oh, rtid, NULL, 0, &num_entries, kvs, NULL); if(ret != 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get list of keys"); + HGOTO_ERROR_FF(FAIL, "can't get list of keys"); for(i=0 ; i<num_entries ; i++) { @@ -1348,7 +1348,7 @@ H5VL_iod_server_iterate(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t rt /* lookup object in the current group */ if(H5VL_iod_get_metadata(obj_oh, rtid, H5VL_IOD_LINK, (char *)(kv[i].key), cs_scope, NULL, &value) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve link value"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve link value"); if(H5L_TYPE_SOFT == value.link_type) { continue; @@ -1362,10 +1362,10 @@ H5VL_iod_server_iterate(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t rt /* Get the object type. */ if((otype = H5VL__iod_get_h5_obj_type(oid, coh, rtid, cs_scope)) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get object type"); + HGOTO_ERROR_FF(FAIL, "can't get object type"); if(H5VL_iod_server_iterate(coh, oid, rtid, otype, cs_scope, op, op_data) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't iterate"); + HGOTO_ERROR_FF(FAIL, "can't iterate"); } for(i=0 ; i<num_entries ; i++) { @@ -1380,7 +1380,7 @@ H5VL_iod_server_iterate(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t rt } if(iod_obj_close(obj_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close current object handle"); + HGOTO_ERROR_FF(FAIL, "can't close current object handle"); } ret_value = ret; @@ -1397,11 +1397,11 @@ H5VL_iod_map_type_convert(hid_t src_id, hid_t dst_id, void *buf, size_t buf_size class = H5Tget_class(src_id); if(H5T_VLEN == class || (H5T_STRING == class && H5Tis_variable_str(src_id))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "Can't convert VL or string types"); + HGOTO_ERROR_FF(FAIL, "Can't convert VL or string types"); class = H5Tget_class(dset_id); if(H5T_VLEN == class || (H5T_STRING == class && H5Tis_variable_str(dst_id))) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "Can't convert VL or string types"); + HGOTO_ERROR_FF(FAIL, "Can't convert VL or string types"); /* Check (and do) Type conversion on the Key */ src_size = H5Tget_size(src_id); @@ -1411,18 +1411,18 @@ H5VL_iod_map_type_convert(hid_t src_id, hid_t dst_id, void *buf, size_t buf_size if(src_size < dst_size) { new_size = dst_size; if(NULL == (*buf = realloc(*buf, new_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "Can't adjust buffer for DT conversion"); + HGOTO_ERROR_FF(FAIL, "Can't adjust buffer for DT conversion"); } else { new_size = src_size; } if(NULL == (key_buf = malloc((size_t)key_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate buffer"); memcpy(key_buf, key.buf, src_size); if(H5Tconvert(src_id, dst_id, 1, key_buf, NULL, dxpl_id) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTINIT, FAIL, "data type conversion failed") + HGOTO_ERROR_FF(FAIL, "data type conversion failed") done: return ret_value; diff --git a/src/H5VLiod_view.c b/src/H5VLiod_view.c index c3e03ee..973b2a0 100644 --- a/src/H5VLiod_view.c +++ b/src/H5VLiod_view.c @@ -63,7 +63,7 @@ H5VL__iod_view_iterate_cb(iod_handle_t coh, iod_obj_id_t obj_id, iod_trans_id_t if((op_data->region_info.regions[i] = H5VL__iod_get_elmt_region(coh, obj_id, rtid, op_data->query_id, op_data->vcpl_id, cs_scope, &op_data->region_info.tokens[i])) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get region from query"); + HGOTO_ERROR_FF(FAIL, "can't get region from query"); op_data->region_info.count ++; } @@ -119,7 +119,7 @@ H5VL_iod_server_view_create_cb(AXE_engine_t UNUSED axe_engine, if((output.region_info.regions[0] = H5VL__iod_get_elmt_region(coh, loc_id, rtid, query_id, vcpl_id, cs_scope, output.region_info.tokens)) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get region from query"); + HGOTO_ERROR_FF(FAIL, "can't get region from query"); output.valid_view = TRUE; output.obj_info.count = 0; @@ -143,7 +143,7 @@ H5VL_iod_server_view_create_cb(AXE_engine_t UNUSED axe_engine, if(H5VL_iod_server_iterate(coh, loc_id, rtid, obj_type, cs_scope, H5VL__iod_view_iterate_cb, &udata) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't iterate to create group"); + HGOTO_ERROR_FF(FAIL, "can't iterate to create group"); output.region_info.count = udata.region_info.count; output.region_info.tokens = udata.region_info.tokens; @@ -221,39 +221,39 @@ H5VL__iod_get_elmt_region(iod_handle_t coh, iod_obj_id_t dset_id, /* Check if VCPL has a dataspace specified; otherwise, read the entire dataset. */ if(H5Pget_view_elmt_scope(vcpl_id, &space_id) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTGET, FAIL, "can't retrieve vcpl region scope");; + HGOTO_ERROR_FF(FAIL, "can't retrieve vcpl region scope");; /* open the array object */ if(iod_obj_open_read(coh, dset_id, rtid, NULL, &dset_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open array object fo read"); + HGOTO_ERROR_FF(FAIL, "can't open array object fo read"); /* get scratch pad */ if(iod_obj_get_scratch(dset_oh, rtid, &sp, &sp_cs, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); if(sp_cs && (cs_scope & H5_CHECKSUM_IOD)) { /* verify scratch pad integrity */ if(H5VL_iod_verify_scratch_pad(&sp, sp_cs) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "Scratch Pad failed integrity check"); + HGOTO_ERROR_FF(FAIL, "Scratch Pad failed integrity check"); } /* open the metadata scratch pad */ if(iod_obj_open_read(coh, sp[0], rtid, NULL, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, 7, NULL, &type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATASPACE, H5VL_IOD_KEY_OBJ_DATASPACE, 7, NULL, &dset_space_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dataspace"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dataspace"); if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_PLIST, H5VL_IOD_KEY_OBJ_CPL, cs_scope, NULL, &dcpl_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve dcpl"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve dcpl"); if(space_id < 0) { use_region_scope = FALSE; @@ -261,7 +261,7 @@ H5VL__iod_get_elmt_region(iod_handle_t coh, iod_obj_id_t dset_id, } if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close iod object"); + HGOTO_ERROR_FF(FAIL, "can't close iod object"); nelmts = (size_t) H5Sget_select_npoints(space_id); elmt_size = H5Tget_size(type_id); @@ -269,21 +269,21 @@ H5VL__iod_get_elmt_region(iod_handle_t coh, iod_obj_id_t dset_id, /* allocate buffer to hold data */ if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* read the data selection from IOD. */ elmt_size = H5Tget_size(type_id); if(H5VL__iod_server_final_io(dset_oh, space_id, elmt_size, FALSE, buf, buf_size, (uint64_t)0, 0, rtid) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); if(iod_obj_close(dset_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close iod object"); + HGOTO_ERROR_FF(FAIL, "can't close iod object"); if(FAIL == (udata.space_query = H5Scopy(space_id))) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTINIT, FAIL, "unable to copy dataspace"); + HGOTO_ERROR_FF(FAIL, "unable to copy dataspace"); if(H5Sselect_none(udata.space_query) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTINIT, FAIL, "unable to reset selection"); + HGOTO_ERROR_FF(FAIL, "unable to reset selection"); udata.query_id = query_id; udata.num_elmts = 0; @@ -291,25 +291,25 @@ H5VL__iod_get_elmt_region(iod_handle_t coh, iod_obj_id_t dset_id, /* iterate over every element and apply the query on it. If the query is not satisfied, then remove it from the query selection */ if(H5Diterate(buf, type_id, space_id, H5VL__iod_get_query_data_cb, &udata) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to compute buffer size"); + HGOTO_ERROR_FF(FAIL, "failed to compute buffer size"); ret_value = udata.space_query; if(H5VL__iod_get_token(H5O_TYPE_DATASET, dset_id, sp[0], sp[1], dcpl_id, type_id, dset_space_id, token) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "failed to get object token"); + HGOTO_ERROR_FF(FAIL, "failed to get object token"); done: if(space_id && H5Sclose(space_id) < 0) - HDONE_ERROR2(H5E_DATASPACE, H5E_CANTRELEASE, FAIL, "unable to release dataspace"); + HDONE_ERROR_FF(FAIL, "unable to release dataspace"); if(use_region_scope) { if(dset_space_id && H5Sclose(dset_space_id) < 0) - HDONE_ERROR2(H5E_DATASPACE, H5E_CANTRELEASE, FAIL, "unable to release dataspace"); + HDONE_ERROR_FF(FAIL, "unable to release dataspace"); } if(type_id && H5Tclose(type_id) < 0) - HDONE_ERROR2(H5E_DATATYPE, H5E_CANTRELEASE, FAIL, "unable to release datatype") + HDONE_ERROR_FF(FAIL, "unable to release datatype") if(dcpl_id && H5Pclose(dcpl_id) < 0) - HDONE_ERROR2(H5E_DATATYPE, H5E_CANTRELEASE, FAIL, "unable to release property list") + HDONE_ERROR_FF(FAIL, "unable to release property list") if(buf != NULL) free(buf); @@ -333,46 +333,46 @@ H5VL__iod_get_token(H5O_type_t obj_type, iod_obj_id_t iod_id, iod_obj_id_t mdkv_ switch(obj_type) { case H5O_TYPE_GROUP: if(H5Pencode(cpl_id, NULL, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); token_size += plist_size + sizeof(size_t); break; case H5O_TYPE_DATASET: if(H5Pencode(cpl_id, NULL, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); if(H5Tencode(id1, NULL, &dt_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); if(H5Sencode(id2, NULL, &space_size) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTENCODE, FAIL, "can't encode dataspace"); + HGOTO_ERROR_FF(FAIL, "can't encode dataspace"); token_size += plist_size + dt_size + space_size + sizeof(size_t)*3; break; case H5O_TYPE_NAMED_DATATYPE: if(H5Pencode(cpl_id, NULL, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); if(H5Tencode(id1, NULL, &dt_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); token_size += plist_size + dt_size + sizeof(size_t)*2; break; case H5O_TYPE_MAP: if(H5Pencode(cpl_id, NULL, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); if(H5Tencode(id1, NULL, &keytype_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); if(H5Tencode(id2, NULL, &valtype_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); token_size += plist_size + keytype_size + valtype_size + sizeof(size_t)*3; break; case H5O_TYPE_UNKNOWN: case H5O_TYPE_NTYPES: default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "bad object"); + HGOTO_ERROR_FF(FAIL, "bad object"); } token->buf_size = token_size; @@ -393,64 +393,64 @@ H5VL__iod_get_token(H5O_type_t obj_type, iod_obj_id_t iod_id, iod_obj_id_t mdkv_ HDmemcpy(buf_ptr, &plist_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Pencode(cpl_id, buf_ptr, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); buf_ptr += plist_size; break; case H5O_TYPE_DATASET: HDmemcpy(buf_ptr, &plist_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Pencode(cpl_id, buf_ptr, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); buf_ptr += plist_size; HDmemcpy(buf_ptr, &dt_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Tencode(id1, buf_ptr, &dt_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); buf_ptr += dt_size; HDmemcpy(buf_ptr, &space_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Sencode(id2, buf_ptr, &space_size) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTENCODE, FAIL, "can't encode dataspace"); + HGOTO_ERROR_FF(FAIL, "can't encode dataspace"); buf_ptr += space_size; break; case H5O_TYPE_NAMED_DATATYPE: HDmemcpy(buf_ptr, &plist_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Pencode(cpl_id, buf_ptr, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); buf_ptr += plist_size; HDmemcpy(buf_ptr, &dt_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Tencode(id1, buf_ptr, &dt_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); buf_ptr += dt_size; break; case H5O_TYPE_MAP: HDmemcpy(buf_ptr, &plist_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Pencode(cpl_id, buf_ptr, &plist_size) < 0) - HGOTO_ERROR2(H5E_PLIST, H5E_CANTENCODE, FAIL, "can't encode plist"); + HGOTO_ERROR_FF(FAIL, "can't encode plist"); buf_ptr += plist_size; HDmemcpy(buf_ptr, &keytype_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Tencode(id1, buf_ptr, &keytype_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); buf_ptr += keytype_size; HDmemcpy(buf_ptr, &valtype_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Tencode(id2, buf_ptr, &valtype_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); buf_ptr += valtype_size; break; case H5O_TYPE_UNKNOWN: case H5O_TYPE_NTYPES: default: - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "bad object"); + HGOTO_ERROR_FF(FAIL, "bad object"); } done: @@ -499,12 +499,12 @@ H5VL_iod_server_get_layout_cb(AXE_engine_t UNUSED axe_engine, if(obj_oh.cookie == IOD_OH_UNDEFINED) { if (iod_obj_open_read(coh, obj_id, NULL /*hints*/, &obj_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); opened_locally = TRUE; } if(iod_obj_get_layout(obj_oh, rtid, &layout, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "can't get object layout"); + HGOTO_ERROR_FF(FAIL, "can't get object layout"); output.ret = ret_value; output.layout = layout @@ -522,7 +522,7 @@ done: /* close the dataset if we opened it in this routine */ if(opened_locally) { if(iod_obj_close(obj_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); } } /* end H5VL_iod_server_get_layout_cb() */ @@ -570,17 +570,17 @@ H5VL_iod_server_view_create_cb(AXE_engine_t UNUSED axe_engine, else if(loc_type == H5I_GROUP || loc_type == H5I_FILE) { if(iod_container_list_obj(coh, rtid, IOD_OBJ_ANY, 0, &token_count, NULL, NULL, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve total number of objects in container"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve total number of objects in container"); } if(NULL == (tokens = (H5VL_token_t *)malloc(sizeof(H5VL_token_t) * token_count))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate token structs"); + HGOTO_ERROR_FF(FAIL, "can't allocate token structs"); if(H5VL__iod_server_construct_view(coh, loc_id, rtid, query, &num_tokens, tokens) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to construct view"); + HGOTO_ERROR_FF(FAIL, "failed to construct view"); if(NULL == (output = (view_create_out_t *)H5MM_malloc(sizeof(view_create_out_t)))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, HG_FAIL, "can't allocate output struct for view create"); + HGOTO_ERROR_FF(FAIL, "can't allocate output struct for view create"); output->ret = ret_value; output->num_tokens = num_tokens; @@ -634,14 +634,14 @@ H5VL_iod_server_get_view_tokens_cb(AXE_engine_t UNUSED axe_engine, /* Write bulk data here and wait for the data to be there */ if(HG_SUCCESS != HG_Bulk_write_all(dest, bulk_handle, bulk_block_handle, &bulk_request)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* wait for it to complete */ if(HG_SUCCESS != HG_Bulk_wait(bulk_request, HG_MAX_IDLE_TIME, HG_STATUS_IGNORE)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); /* free block handle */ if(HG_SUCCESS != HG_Bulk_block_handle_free(bulk_block_handle)) - HGOTO_ERROR2(H5E_SYM, H5E_READERROR, FAIL, "can't free bds block handle"); + HGOTO_ERROR_FF(FAIL, "can't free bds block handle"); HG_Handler_start_output(op_data->hg_handle, output); @@ -676,14 +676,14 @@ H5VL__iod_server_construct_view(iod_handle_t coh, iod_obj_id_t loc_id, iod_trans location object */ if(query_type & H5Q_TYPE_ATTR_NAME) { if(H5VL_iod_query_attribute(coh, rtid, loc_id, query, num_tokens, tokens) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to query dataset for selection"); + HGOTO_ERROR_FF(FAIL, "unable to query dataset for selection"); } if(loc_id & IOD_OBJ_TYPE_ARRAY) { /* get token for dataset and space selection for data elements that satisfy the query */ if(H5VL_iod_query_selection(coh, rtid, loc_id, query, num_tokens, tokens) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to query dataset for selection"); + HGOTO_ERROR_FF(FAIL, "unable to query dataset for selection"); } else if(loc_id & IOD_OBJ_TYPE_KV) { @@ -693,7 +693,7 @@ H5VL__iod_server_construct_view(iod_handle_t coh, iod_obj_id_t loc_id, iod_trans has a link from the current location object. */ if(query_type & H5Q_TYPE_LINK_NAME) { if(H5VL_iod_query_link(coh, rtid, loc_id, query, num_tokens, tokens) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "unable to query dataset for selection"); + HGOTO_ERROR_FF(FAIL, "unable to query dataset for selection"); } } @@ -729,24 +729,24 @@ H5VL__iod_query_selection(iod_handle_t coh, iod_obj_id_t obj_id, /* open the array object */ if (iod_obj_open_read(coh, obj_id, NULL /*hints*/, &obj_oh, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't open current group"); + HGOTO_ERROR_FF(FAIL, "can't open current group"); /* get scratch pad of the dataset */ if(iod_obj_get_scratch(obj_oh, rtid, &sp, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't get scratch pad for object"); + HGOTO_ERROR_FF(FAIL, "can't get scratch pad for object"); /* open the metadata scratch pad */ if (iod_obj_open_write(coh, sp[0], NULL /*hints*/, &mdkv_oh, NULL) < 0) - HGOTO_ERROR2(H5E_FILE, H5E_CANTINIT, FAIL, "can't open scratch pad"); + HGOTO_ERROR_FF(FAIL, "can't open scratch pad"); /* retrieve the datatype of array object */ if(H5VL_iod_get_metadata(mdkv_oh, rtid, H5VL_IOD_DATATYPE, H5VL_IOD_KEY_OBJ_DATATYPE, NULL, NULL, type_id) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTGET, FAIL, "failed to retrieve datatype"); + HGOTO_ERROR_FF(FAIL, "failed to retrieve datatype"); /* close the metadata scratch pad */ if(iod_obj_close(mdkv_oh, NULL, NULL) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close object"); + HGOTO_ERROR_FF(FAIL, "can't close object"); /* get layout dataspace from the query to read from */ layout_space = H5Qget_space(query); @@ -757,21 +757,21 @@ H5VL__iod_query_selection(iod_handle_t coh, iod_obj_id_t obj_id, /* allocate buffer to hold data */ if(NULL == (buf = malloc(buf_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate read buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate read buffer"); /* read the data selection from IOD. */ /* MSC - will need to do it in pieces, not it one shot. */ if(H5VL__iod_server_final_io(coh, obj_oh, layout_space, type_id, FALSE, buf, buf_size, 0, 0, rtid) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTREAD, FAIL, "can't read from array object"); + HGOTO_ERROR_FF(FAIL, "can't read from array object"); if(H5Qapply(query, buf, type_id, layout_space, H5P_DEFAULT, &queried_space) < 0) - HGOTO_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't apply query on dataspace"); + HGOTO_ERROR_FF(FAIL, "can't apply query on dataspace"); if(H5Sencode(queried_space, NULL, &ds_size) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTENCODE, FAIL, "can't encode dataspace"); + HGOTO_ERROR_FF(FAIL, "can't encode dataspace"); if(H5Tencode(type_id, NULL, &dt_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); token_size += sizeof(iod_obj_id_t)*3 + sizeof(H5O_type_t) + dt_size + ds_size + sizeof(size_t)*2; @@ -780,7 +780,7 @@ H5VL__iod_query_selection(iod_handle_t coh, iod_obj_id_t obj_id, tokens[u].token_size = token_size; if(NULL == (tokens[u].token = malloc(token_size))) - HGOTO_ERROR2(H5E_SYM, H5E_NOSPACE, FAIL, "can't allocate token buffer"); + HGOTO_ERROR_FF(FAIL, "can't allocate token buffer"); buf_ptr = (uint8_t *)tokens[u].token; @@ -797,13 +797,13 @@ H5VL__iod_query_selection(iod_handle_t coh, iod_obj_id_t obj_id, HDmemcpy(buf_ptr, &dt_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Tencode(type_id, buf_ptr, &dt_size) < 0) - HGOTO_ERROR2(H5E_DATATYPE, H5E_CANTENCODE, FAIL, "can't encode datatype"); + HGOTO_ERROR_FF(FAIL, "can't encode datatype"); buf_ptr += dt_size; HDmemcpy(buf_ptr, &ds_size, sizeof(size_t)); buf_ptr += sizeof(size_t); if(H5Sencode(queried_space, buf_ptr, &ds_size) < 0) - HGOTO_ERROR2(H5E_DATASPACE, H5E_CANTENCODE, FAIL, "can't encode dataspace"); + HGOTO_ERROR_FF(FAIL, "can't encode dataspace"); buf_ptr += space_size; *num_tokens ++; @@ -819,7 +819,7 @@ done: free(buf); if(obj_oh != IOD_OH_UNDEFINED && iod_obj_close(obj_oh, NULL, NULL) < 0) - HDONE_ERROR2(H5E_SYM, H5E_CANTINIT, FAIL, "can't close Array object"); + HDONE_ERROR_FF(FAIL, "can't close Array object"); return ret_value; } /* end H5VL__iod_query_selection() */ |