diff options
Diffstat (limited to 'tools/test')
-rw-r--r-- | tools/test/h5copy/h5copygentest.c | 110 | ||||
-rw-r--r-- | tools/test/h5diff/h5diffgentest.c | 446 | ||||
-rw-r--r-- | tools/test/h5dump/h5dumpgentest.c | 46 | ||||
-rw-r--r-- | tools/test/h5import/h5importtest.c | 168 | ||||
-rw-r--r-- | tools/test/h5jam/h5jamgentest.c | 6 | ||||
-rw-r--r-- | tools/test/h5repack/h5repacktst.c | 120 | ||||
-rw-r--r-- | tools/test/h5repack/testh5repack_detect_szip.c | 4 | ||||
-rw-r--r-- | tools/test/h5stat/h5stat_gentest.c | 14 | ||||
-rw-r--r-- | tools/test/misc/h5clear_gentest.c | 138 | ||||
-rw-r--r-- | tools/test/misc/talign.c | 26 |
10 files changed, 539 insertions, 539 deletions
diff --git a/tools/test/h5copy/h5copygentest.c b/tools/test/h5copy/h5copygentest.c index 9f5d916..f6aa72f 100644 --- a/tools/test/h5copy/h5copygentest.c +++ b/tools/test/h5copy/h5copygentest.c @@ -326,7 +326,7 @@ static void gent_nested_vl(hid_t loc_id) * Function: gent_att_compound_vlstr * * Purpose: Generate a dataset and a group. - * Both has an attribute with a compound datatype consisting + * Both has an attribute with a compound datatype consisting * of a variable length string * *------------------------------------------------------------------------- @@ -337,15 +337,15 @@ static void gent_att_compound_vlstr(hid_t loc_id) int i; const char *v; } s1; - hsize_t dim[1] = {1}; /* Dimension size */ - hid_t sid = -1; /* Dataspace ID */ - hid_t tid = -1; /* Datatype ID */ - hid_t aid = -1; /* Attribute ID */ - hid_t did = -1; /* Dataset ID */ - hid_t gid = -1; /* Group ID */ - hid_t vl_str_tid = -1; /* Variable length datatype ID */ - hid_t cmpd_tid = -1; /* Compound datatype ID */ - hid_t null_sid = -1; /* Null dataspace ID */ + hsize_t dim[1] = {1}; /* Dimension size */ + hid_t sid = -1; /* Dataspace ID */ + hid_t tid = -1; /* Datatype ID */ + hid_t aid = -1; /* Attribute ID */ + hid_t did = -1; /* Dataset ID */ + hid_t gid = -1; /* Group ID */ + hid_t vl_str_tid = -1; /* Variable length datatype ID */ + hid_t cmpd_tid = -1; /* Compound datatype ID */ + hid_t null_sid = -1; /* Null dataspace ID */ s1 buf; /* Buffer */ buf.i = 9; @@ -509,7 +509,7 @@ static herr_t gen_obj_ref(hid_t loc_id) sid = H5Screate_simple(1, dims1, NULL); if (sid < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -517,7 +517,7 @@ static herr_t gen_obj_ref(hid_t loc_id) oid = H5Dcreate2 (loc_id, OBJ_REF_DS, H5T_NATIVE_INT, sid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (oid < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -525,7 +525,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Dwrite(oid, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -538,7 +538,7 @@ static herr_t gen_obj_ref(hid_t loc_id) oid = H5Gcreate2 (loc_id, OBJ_REF_GRP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (oid < 0) { - fprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -547,14 +547,14 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Rcreate (&or_data[0], loc_id, OBJ_REF_DS, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } status = H5Rcreate (&or_data[1], loc_id, OBJ_REF_GRP, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -562,7 +562,7 @@ static herr_t gen_obj_ref(hid_t loc_id) sid = H5Screate_simple (1, dims2, NULL); if (sid < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -570,7 +570,7 @@ static herr_t gen_obj_ref(hid_t loc_id) oid = H5Dcreate2 (loc_id, "Dset_OBJREF", H5T_STD_REF_OBJ, sid, H5P_DEFAULT,H5P_DEFAULT,H5P_DEFAULT); if (oid < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -578,7 +578,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Dwrite(oid, H5T_STD_REF_OBJ, H5S_ALL, H5S_ALL, H5P_DEFAULT, or_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -618,7 +618,7 @@ static herr_t gen_region_ref(hid_t loc_id) sid = H5Screate_simple (2, dims2, NULL); if (sid < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -627,7 +627,7 @@ static herr_t gen_region_ref(hid_t loc_id) oid2 = H5Dcreate2 (loc_id, REG_REF_DS2, H5T_STD_I8LE, sid, H5P_DEFAULT,H5P_DEFAULT,H5P_DEFAULT); if (oid2 < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -636,7 +636,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Dwrite (oid2, H5T_NATIVE_CHAR, H5S_ALL, H5S_ALL, H5P_DEFAULT, data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -645,7 +645,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Sselect_elements (sid, H5S_SELECT_SET, 4, coords[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -654,7 +654,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Rcreate (&rr_data[0], loc_id, REG_REF_DS2, H5R_DATASET_REGION, sid); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -663,7 +663,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Sselect_hyperslab (sid, H5S_SELECT_SET, start, stride, count, block); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_hyperslab failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_hyperslab failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -672,7 +672,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Rcreate (&rr_data[1], loc_id, REG_REF_DS2, H5R_DATASET_REGION, sid); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -683,7 +683,7 @@ static herr_t gen_region_ref(hid_t loc_id) sid = H5Screate_simple (1, dims1, NULL); if (sid < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -692,7 +692,7 @@ static herr_t gen_region_ref(hid_t loc_id) oid1 = H5Dcreate2 (loc_id, REG_REF_DS1, H5T_STD_REF_DSETREG, sid, H5P_DEFAULT,H5P_DEFAULT,H5P_DEFAULT); if (oid1 < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -701,7 +701,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Dwrite (oid1, H5T_STD_REF_DSETREG, H5S_ALL, H5S_ALL, H5P_DEFAULT, rr_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -725,30 +725,30 @@ out: *------------------------------------------------------------------------*/ static void Test_Obj_Copy(void) { - hid_t fid = -1; /* File id */ - hid_t fapl_new = (-1); /* File access property id */ - unsigned new_format; /* New format or old format */ + hid_t fid = -1; /* File id */ + hid_t fapl_new = (-1); /* File access property id */ + unsigned new_format; /* New format or old format */ if((fapl_new = H5Pcreate(H5P_FILE_ACCESS)) < 0) { - fprintf(stderr, "Error: H5Pcreate failed.\n"); + HDfprintf(stderr, "Error: H5Pcreate failed.\n"); goto out; } if(H5Pset_libver_bounds(fapl_new, H5F_LIBVER_LATEST, H5F_LIBVER_LATEST) < 0) { - fprintf(stderr, "Error: H5Pset_libver_bounds failed.\n"); + HDfprintf(stderr, "Error: H5Pset_libver_bounds failed.\n"); goto out; } /* Test with old & new format groups */ for(new_format = FALSE; new_format <= TRUE; new_format++) { - + /* Set the FAPL for the type of format */ /* Create source file */ if(new_format) - fid = H5Fcreate(HDF_FILE1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl_new); - else - fid = H5Fcreate(HDF_FILE1_NEW, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); + fid = H5Fcreate(HDF_FILE1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl_new); + else + fid = H5Fcreate(HDF_FILE1_NEW, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if(fid < 0) { - fprintf(stderr, "Error: H5Fcreate failed.\n"); + HDfprintf(stderr, "Error: H5Fcreate failed.\n"); goto out; } @@ -756,7 +756,7 @@ static void Test_Obj_Copy(void) gent_empty_group(fid); gent_nested_datasets(fid); gent_nested_group(fid); - gent_att_compound_vlstr(fid); + gent_att_compound_vlstr(fid); H5Fclose(fid); fid = (-1); @@ -786,19 +786,19 @@ static void Test_Ref_Copy(void) fid = H5Fcreate (HDF_FILE2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", HDF_FILE2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", HDF_FILE2); goto out; } /* add object reference */ status = gen_obj_ref(fid); if (status < 0) - fprintf(stderr, "Failed to generate object reference.\n"); + HDfprintf(stderr, "Failed to generate object reference.\n"); /* add region reference */ status = gen_region_ref(fid); if (status < 0) - fprintf(stderr, "Failed to generate region reference.\n"); + HDfprintf(stderr, "Failed to generate region reference.\n"); out: /*----------------------------------------------------------------------- @@ -829,7 +829,7 @@ static herr_t gen_extlink_trg(hid_t loc_id) gid = H5Gcreate2(loc_id, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid < 0) { - fprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -845,7 +845,7 @@ static herr_t gen_extlink_trg(hid_t loc_id) status = H5Tcommit2(loc_id, "datatype", tid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Tcommit2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Tcommit2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -878,7 +878,7 @@ static herr_t gen_extlink_src(hid_t loc_id) gid = H5Gcreate2(loc_id, "/group_ext", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid < 0) { - fprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -890,7 +890,7 @@ static herr_t gen_extlink_src(hid_t loc_id) status = H5Lcreate_external(HDF_EXT_TRG_FILE, "/simple", gid, "extlink_dset", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -899,7 +899,7 @@ static herr_t gen_extlink_src(hid_t loc_id) status = H5Lcreate_external(HDF_EXT_TRG_FILE, "/group", gid, "extlink_grp", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -908,7 +908,7 @@ static herr_t gen_extlink_src(hid_t loc_id) status = H5Lcreate_external(HDF_EXT_TRG_FILE, "/datatype", gid, "extlink_datatype", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -917,7 +917,7 @@ static herr_t gen_extlink_src(hid_t loc_id) status = H5Lcreate_external(HDF_EXT_TRG_FILE, "notyet", gid, "extlink_notyet1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -926,7 +926,7 @@ static herr_t gen_extlink_src(hid_t loc_id) status = H5Lcreate_external("notyet_file.h5", "notyet", gid, "extlink_notyet2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Lcreate_external failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -953,26 +953,26 @@ static void Test_Extlink_Copy(void) fid1 = H5Fcreate (HDF_EXT_SRC_FILE, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", HDF_EXT_SRC_FILE); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", HDF_EXT_SRC_FILE); goto out; } fid2 = H5Fcreate (HDF_EXT_TRG_FILE, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", HDF_EXT_TRG_FILE); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", HDF_EXT_TRG_FILE); goto out; } /* add links to source external link file */ status = gen_extlink_src(fid1); if (status < 0) - fprintf(stderr, "Error: %s> gen_extlink_src failed.\n", HDF_EXT_SRC_FILE); + HDfprintf(stderr, "Error: %s> gen_extlink_src failed.\n", HDF_EXT_SRC_FILE); /* add objs to target external link file */ status = gen_extlink_trg(fid2); if (status < 0) - fprintf(stderr, "Error: %s> gen_extlink_trg failed.\n", HDF_EXT_TRG_FILE); + HDfprintf(stderr, "Error: %s> gen_extlink_trg failed.\n", HDF_EXT_TRG_FILE); out: /*----------------------------------------------------------------------- diff --git a/tools/test/h5diff/h5diffgentest.c b/tools/test/h5diff/h5diffgentest.c index 4f92cae..d60e393 100644 --- a/tools/test/h5diff/h5diffgentest.c +++ b/tools/test/h5diff/h5diffgentest.c @@ -310,11 +310,11 @@ int test_basic(const char *fname1, const char *fname2, const char *fname3) /* create the empty file */ if ((fid1 = H5Fcreate(fname3, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0) { - fprintf(stderr, "empty file (%s) creation failed.\n", fname3); + HDfprintf(stderr, "empty file (%s) creation failed.\n", fname3); goto out; } if (H5Fclose(fid1) < 0) { - fprintf(stderr, "empty file (%s) close failed.\n", fname3); + HDfprintf(stderr, "empty file (%s) close failed.\n", fname3); goto out; } @@ -1065,7 +1065,7 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) * Create file1 *-----------------------------------------------------------------------*/ if ((fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -1075,28 +1075,28 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) */ f1_gid = H5Gcreate2(fid1, "g", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f1_gid < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } f1_gid2 = H5Gcreate2(fid1, "g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f1_gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } f1_gid3 = H5Gcreate2(fid1, "g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f1_gid3 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } f1_gid4 = H5Gcreate2(fid1, "g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f1_gid4 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -1107,13 +1107,13 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) f1_sid = H5Screate_simple(1, dset_dims, NULL); f1_did = H5Dcreate2(fid1, "dset", H5T_NATIVE_INT, f1_sid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f1_did == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = H5Dwrite(f1_did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, dset_data); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -1124,7 +1124,7 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) f1_tid = H5Tcopy(H5T_NATIVE_INT); status = H5Tcommit2(fid1, "ntype", f1_tid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tcommit2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tcommit2 failed.\n", fname1); status = FAIL; goto out; } @@ -1133,7 +1133,7 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) * Create file2 *-----------------------------------------------------------------------*/ if ((fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -1143,28 +1143,28 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) */ f2_gid = H5Gcreate2(fid2, "g", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f2_gid < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } f2_gid2 = H5Gcreate2(fid2, "g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f2_gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } f2_gid3 = H5Gcreate2(fid2, "g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f2_gid3 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } f2_gid4 = H5Gcreate2(fid2, "g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f2_gid4 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -1175,13 +1175,13 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) f2_sid = H5Screate_simple(1, dset_dims, NULL); f2_did = H5Dcreate2(fid2, "dset", H5T_NATIVE_INT, f2_sid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (f2_did == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = H5Dwrite(f2_did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, dset_data); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname2); status = FAIL; goto out; } @@ -1192,7 +1192,7 @@ static int test_attributes_verbose_level(const char *fname1, const char *fname2) f2_tid = H5Tcopy(H5T_NATIVE_INT); status = H5Tcommit2(fid2, "ntype", f2_tid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tcommit2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Tcommit2 failed.\n", fname2); status = FAIL; goto out; } @@ -1423,7 +1423,7 @@ static int test_link_name(const char *fname1) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -1433,7 +1433,7 @@ static int test_link_name(const char *fname1) *------------------------------------------------------------------------*/ gid1 = H5Gcreate2(fid1, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -1441,7 +1441,7 @@ static int test_link_name(const char *fname1) H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -1451,14 +1451,14 @@ static int test_link_name(const char *fname1) *------------------------------------------------------------------------*/ status = H5Lcreate_soft("group", fid1, "link_g1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("group_longname", fid1, "link_g2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } @@ -1498,7 +1498,7 @@ static int test_soft_links(const char *fname1) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -1508,7 +1508,7 @@ static int test_soft_links(const char *fname1) *------------------------------------------------------------------------*/ gid1 = H5Gcreate2(fid1, "target_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -1519,21 +1519,21 @@ static int test_soft_links(const char *fname1) /* file1 */ status = write_dset(fid1, 2, dims2, "target_dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(fid1, 2, dims2, "target_dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "dset", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -1544,42 +1544,42 @@ static int test_soft_links(const char *fname1) /* file 1 */ status = H5Lcreate_soft("/target_dset1", fid1, "softlink_dset1_1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/target_dset1", fid1, "softlink_dset1_2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/target_dset2", fid1, "softlink_dset2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/target_group", fid1, "softlink_group1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/target_group", fid1, "softlink_group2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/no_obj", fid1, "softlink_noexist", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } @@ -1619,7 +1619,7 @@ static int test_linked_softlinks(const char *fname1) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -1629,21 +1629,21 @@ static int test_linked_softlinks(const char *fname1) *------------------------------------------------------------------------*/ gid1 = H5Gcreate2(fid1, "target_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } gid2 = H5Gcreate2(fid1, "target_group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } gid3 = H5Gcreate2(fid1, "target_group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid3 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -1654,20 +1654,20 @@ static int test_linked_softlinks(const char *fname1) /* file1 */ status = write_dset(fid1, 2, dims2, "target_dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(fid1, 2, dims2, "target_dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "dset", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -1679,84 +1679,84 @@ static int test_linked_softlinks(const char *fname1) * file 1 */ status = H5Lcreate_soft("/target_dset1", fid1, "softlink1_to_dset1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink1_to_dset1", fid1, "softlink1_to_slink1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink1_to_slink1", fid1, "softlink1_to_slink2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/target_dset2", fid1, "softlink2_to_dset2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink2_to_dset2", fid1, "softlink2_to_slink1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink2_to_slink1", fid1, "softlink2_to_slink2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("target_group1", fid1, "softlink3_to_group1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink3_to_group1", fid1, "softlink3_to_slink1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink3_to_slink1", fid1, "softlink3_to_slink2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("target_group2", fid1, "softlink4_to_group2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink4_to_group2", fid1, "softlink4_to_slink1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("softlink4_to_slink1", fid1, "softlink4_to_slink2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } @@ -1801,7 +1801,7 @@ static int test_external_links(const char *fname1, const char *fname2) /* source file */ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -1809,7 +1809,7 @@ static int test_external_links(const char *fname1, const char *fname2) /* target file */ fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -1821,14 +1821,14 @@ static int test_external_links(const char *fname1, const char *fname2) * target file */ gid1 = H5Gcreate2(fid2, "target_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } gid2 = H5Gcreate2(fid2, "target_group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -1839,21 +1839,21 @@ static int test_external_links(const char *fname1, const char *fname2) * target file */ status = write_dset(fid2, 2, dims2, "target_dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "x_dset", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid2, 2, dims2, "x_dset", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -1865,42 +1865,42 @@ static int test_external_links(const char *fname1, const char *fname2) /* source file */ status = H5Lcreate_external(fname2, "/target_group/x_dset", fid1, "ext_link_dset1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/target_group2/x_dset", fid1, "ext_link_dset2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/target_group", fid1, "/ext_link_grp1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/target_group2", fid1, "/ext_link_grp2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "no_obj", fid1, "ext_link_noexist1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external("no_file.h5", "no_obj", fid1, "ext_link_noexist2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } @@ -1945,7 +1945,7 @@ static int test_ext2soft_links(const char *fname1, const char *fname2) /* source file */ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -1953,7 +1953,7 @@ static int test_ext2soft_links(const char *fname1, const char *fname2) /* target file */ fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -1964,7 +1964,7 @@ static int test_ext2soft_links(const char *fname1, const char *fname2) /* target file */ gid2 = H5Gcreate2(fid2, "target_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -1976,14 +1976,14 @@ static int test_ext2soft_links(const char *fname1, const char *fname2) * target file */ status = write_dset(fid2, 2, dims2, "dset1", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(fid2, 2, dims2, "dset2", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -1995,14 +1995,14 @@ static int test_ext2soft_links(const char *fname1, const char *fname2) * target file */ status = H5Lcreate_soft("/dset1", fid2, "softlink_to_dset1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("/dset2", fid2, "softlink_to_dset2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } @@ -2014,21 +2014,21 @@ static int test_ext2soft_links(const char *fname1, const char *fname2) * source file */ status = H5Lcreate_external(fname2, "/target_group", fid1, "ext_link", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/softlink_to_dset1", fid1, "ext_link_to_slink1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/softlink_to_dset2", fid1, "ext_link_to_slink2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } @@ -2158,14 +2158,14 @@ static int test_dangle_links(const char *fname1, const char *fname2) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -2176,14 +2176,14 @@ static int test_dangle_links(const char *fname1, const char *fname2) /* file1 */ status = write_dset(fid1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(fid1, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -2191,14 +2191,14 @@ static int test_dangle_links(const char *fname1, const char *fname2) /* file2 */ status = write_dset(fid2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(fid2, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -2209,28 +2209,28 @@ static int test_dangle_links(const char *fname1, const char *fname2) /* file 1 */ status = H5Lcreate_soft("no_obj", fid1, "soft_link1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/dset1", fid1, "soft_link2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("no_obj", fid1, "soft_link3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("no_obj1", fid1, "soft_link4", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } @@ -2238,28 +2238,28 @@ static int test_dangle_links(const char *fname1, const char *fname2) /* file 2 */ status = H5Lcreate_soft("no_obj", fid2, "soft_link1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("no_obj", fid2, "soft_link2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("/dset2", fid2, "soft_link3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("no_obj2", fid2, "soft_link4", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } @@ -2270,28 +2270,28 @@ static int test_dangle_links(const char *fname1, const char *fname2) /* file1 */ status = H5Lcreate_external(fname2, "no_obj", fid1, "ext_link1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/dset1", fid1, "ext_link2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "no_obj", fid1, "ext_link3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external("no_file.h5", "no_obj", fid1, "ext_link4", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } @@ -2299,28 +2299,28 @@ static int test_dangle_links(const char *fname1, const char *fname2) /* file2 */ status = H5Lcreate_external(fname1, "no_obj", fid2, "ext_link1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_external(fname1, "no_obj", fid2, "ext_link2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_external(fname1, "/dset2", fid2, "ext_link3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_external("no_file.h5", "no_obj", fid2, "ext_link4", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } @@ -2361,14 +2361,14 @@ static int test_group_recurse(const char *fname1, const char *fname2) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -2379,28 +2379,28 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file1 */ gid1_f1 = H5Gcreate2(fid1, "/grp1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1_f1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } gid2_f1 = H5Gcreate2(fid1, "/grp1/grp2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2_f1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } gid3_f1 = H5Gcreate2(fid1, "/grp1/grp2/grp3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid3_f1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } gid10_f1 = H5Gcreate2(fid1, "/grp10", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid10_f1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -2408,28 +2408,28 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file2 */ gid1_f2 = H5Gcreate2(fid2, "/grp1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1_f2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } gid2_f2 = H5Gcreate2(fid2, "/grp1/grp2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2_f2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } gid3_f2 = H5Gcreate2(fid2, "/grp1/grp2/grp3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid3_f2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } gid11_f2 = H5Gcreate2(fid2, "/grp11", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid11_f2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -2440,21 +2440,21 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file1 */ status = write_dset(fid1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(fid1, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(fid1, 2, dims2, "dset3", H5T_NATIVE_INT, data3); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -2462,21 +2462,21 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file2 */ status = write_dset(fid2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(fid2, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(fid2, 2, dims2, "dset3", H5T_NATIVE_INT, data3); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -2487,54 +2487,54 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file1 */ status = write_dset(gid1_f1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid2_f1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid2_f1, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid3_f1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid3_f1, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid3_f1, 2, dims2, "dset3", H5T_NATIVE_INT, data3); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid10_f1, 2, dims2, "dset4", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid10_f1, 2, dims2, "dset5", H5T_NATIVE_INT, data3); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -2542,54 +2542,54 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file2 */ status = write_dset(gid1_f2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid2_f2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid2_f2, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid3_f2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid3_f2, 2, dims2, "dset2", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid3_f2, 2, dims2, "dset3", H5T_NATIVE_INT, data3); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid11_f2, 2, dims2, "dset4", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid11_f2, 2, dims2, "dset5", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -2600,28 +2600,28 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file 1 */ status = H5Lcreate_soft("/grp1", fid1, "slink_grp1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/grp1/grp2", fid1, "slink_grp2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/grp1/grp2/grp3", fid1, "slink_grp3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_soft("/grp10", fid1, "slink_grp10", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname1); status = FAIL; goto out; } @@ -2629,28 +2629,28 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file 2 */ status = H5Lcreate_soft("/grp1", fid2, "slink_grp1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("/grp1/grp2", fid2, "slink_grp2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("/grp1/grp2/grp3", fid2, "slink_grp3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_soft("/grp11", fid2, "slink_grp11", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", fname2); status = FAIL; goto out; } @@ -2661,21 +2661,21 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file1 */ status = H5Lcreate_external(fname2, "/grp1", fid1, "elink_grp1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/grp1/grp2", fid1, "elink_grp2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } status = H5Lcreate_external(fname2, "/grp1/grp2/grp3", fid1, "elink_grp3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } @@ -2683,21 +2683,21 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file2 */ status = H5Lcreate_external(fname1, "/grp1", fid2, "elink_grp1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_external(fname1, "/grp1/grp2", fid2, "elink_grp2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } status = H5Lcreate_external(fname1, "/grp1/grp2/grp3", fid2, "elink_grp3", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } @@ -2709,14 +2709,14 @@ static int test_group_recurse(const char *fname1, const char *fname2) /* file1 */ status = H5Lcreate_external(fname2, "/grp11", gid10_f1, "elink_grp_circle", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname1); status = FAIL; goto out; } /* file2 */ status = H5Lcreate_external(fname1, "/grp10", gid11_f2, "elink_grp_circle", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", fname2); status = FAIL; goto out; } @@ -2790,28 +2790,28 @@ static int test_group_recurse2(void) *------------------------------------------------------------------------*/ grp1 = H5Gcreate2(fileid1, "/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); status = FAIL; goto out; } grp2 = H5Gcreate2(grp1, "g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); status = FAIL; goto out; } grp3 = H5Gcreate2(grp2, "g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp3 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); status = FAIL; goto out; } grp4 = H5Gcreate2(grp3, "g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp4 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); status = FAIL; goto out; } @@ -2886,7 +2886,7 @@ static int test_group_recurse2(void) /* link to dset1 */ status = H5Lcreate_soft(GRP_R_DSETNAME1, fileid1, "soft_dset1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", GRP_RECURSE1_EXT); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", GRP_RECURSE1_EXT); status = FAIL; goto out; } @@ -2910,7 +2910,7 @@ static int test_group_recurse2(void) */ grp4 = H5Gcreate2(fileid4, "/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp4 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE2_EXT3); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE2_EXT3); status = FAIL; goto out; } @@ -2944,14 +2944,14 @@ static int test_group_recurse2(void) */ grp2 = H5Gcreate2(fileid3, "g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE2_EXT2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE2_EXT2); status = FAIL; goto out; } grp3 = H5Gcreate2(grp2, "g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp3 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE2_EXT2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE2_EXT2); status = FAIL; goto out; } @@ -2975,7 +2975,7 @@ static int test_group_recurse2(void) */ status = H5Lcreate_external(GRP_RECURSE2_EXT3, "/g4", fileid3, "/g2/g3/g4", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", GRP_RECURSE2_EXT2); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", GRP_RECURSE2_EXT2); status = FAIL; goto out; } @@ -2996,7 +2996,7 @@ static int test_group_recurse2(void) */ grp1 = H5Gcreate2(fileid2, "g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (grp1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", GRP_RECURSE1_EXT); status = FAIL; goto out; } @@ -3020,7 +3020,7 @@ static int test_group_recurse2(void) /* link to dset1 */ status = H5Lcreate_soft(GRP_R_DSETNAME1, fileid2, "soft_dset1", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", GRP_RECURSE2_EXT1); + HDfprintf(stderr, "Error: %s> H5Lcreate_soft failed.\n", GRP_RECURSE2_EXT1); status = FAIL; goto out; } @@ -3030,7 +3030,7 @@ static int test_group_recurse2(void) */ status = H5Lcreate_external(GRP_RECURSE2_EXT2, "/g2", fileid2, "/g1/g2", H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", GRP_RECURSE2_EXT1); + HDfprintf(stderr, "Error: %s> H5Lcreate_external failed.\n", GRP_RECURSE2_EXT1); status = FAIL; goto out; } @@ -3083,14 +3083,14 @@ static int test_exclude_obj1(const char *fname1, const char *fname2) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -3101,7 +3101,7 @@ static int test_exclude_obj1(const char *fname1, const char *fname2) /* file1 */ gid1 = H5Gcreate2(fid1, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -3110,7 +3110,7 @@ static int test_exclude_obj1(const char *fname1, const char *fname2) gid2 = H5Gcreate2(fid2, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -3121,21 +3121,21 @@ static int test_exclude_obj1(const char *fname1, const char *fname2) /* file1 */ status = write_dset(fid1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "dset2", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "dset3", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -3143,21 +3143,21 @@ static int test_exclude_obj1(const char *fname1, const char *fname2) /* file2 */ status = write_dset(fid2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid2, 2, dims2, "dset2", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid2, 2, dims2, "dset3", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -3204,14 +3204,14 @@ static int test_exclude_obj2(const char *fname1, const char *fname2) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -3222,7 +3222,7 @@ static int test_exclude_obj2(const char *fname1, const char *fname2) /* file1 */ gid1 = H5Gcreate2(fid1, "group10", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -3230,7 +3230,7 @@ static int test_exclude_obj2(const char *fname1, const char *fname2) /* file2 */ gid2 = H5Gcreate2(fid2, "group10", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -3239,7 +3239,7 @@ static int test_exclude_obj2(const char *fname1, const char *fname2) gid3 = H5Gcreate2(fid2, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid3 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname2); status = FAIL; goto out; } @@ -3250,21 +3250,21 @@ static int test_exclude_obj2(const char *fname1, const char *fname2) /* file1 */ status = write_dset(fid1, 2, dims2, "dset10", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(fid1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "dset2", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -3272,21 +3272,21 @@ static int test_exclude_obj2(const char *fname1, const char *fname2) /* file2 */ status = write_dset(fid2, 2, dims2, "dset10", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid2, 2, dims2, "dset2", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } status = write_dset(gid3, 2, dims2, "dset3", H5T_NATIVE_INT, data2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -3332,14 +3332,14 @@ static int test_exclude_obj3(const char *fname1, const char *fname2) *------------------------------------------------------------------------*/ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); status = FAIL; goto out; } @@ -3350,7 +3350,7 @@ static int test_exclude_obj3(const char *fname1, const char *fname2) /* file1 */ gid1 = H5Gcreate2(fid1, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -3361,14 +3361,14 @@ static int test_exclude_obj3(const char *fname1, const char *fname2) /* file1 */ status = write_dset(fid1, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } status = write_dset(gid1, 2, dims2, "dset", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname1); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname1); status = FAIL; goto out; } @@ -3376,7 +3376,7 @@ static int test_exclude_obj3(const char *fname1, const char *fname2) /* file2 */ status = write_dset(fid2, 2, dims2, "dset1", H5T_NATIVE_INT, data1); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname2); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname2); status = FAIL; goto out; } @@ -3698,7 +3698,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int if (is_file_new == 1) { fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); status = FAIL; goto out; } @@ -3706,7 +3706,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int else { fid1 = H5Fopen(fname1, H5F_ACC_RDWR, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fopen failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fopen failed.\n", fname1); status = FAIL; goto out; } @@ -3717,7 +3717,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int *------------------------------------------------------------------------*/ gid = H5Gcreate2(fid1, grp_name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname1); status = FAIL; goto out; } @@ -3727,7 +3727,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int *------------------------------------------------------------------------*/ sid_vlen_str = H5Screate_simple(STR_RANK, dims_vlen_str, NULL); if (sid_vlen_str < 0) { - fprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); status = FAIL; goto out; } @@ -3735,7 +3735,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int tid_vlen_str = H5Tcopy(H5T_C_S1); status = H5Tset_size(tid_vlen_str, H5T_VARIABLE); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); status = FAIL; goto out; } @@ -3745,7 +3745,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int *------------------------------------------------------------------------*/ sid_fixlen_str = H5Screate_simple(STR_RANK, dims_fixlen_str, NULL); if (sid_fixlen_str < 0) { - fprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); status = FAIL; goto out; } @@ -3753,7 +3753,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int tid_fixlen_str = H5Tcopy(H5T_C_S1); status = H5Tset_size(tid_fixlen_str, FIXLEN_STR_SIZE); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); status = FAIL; goto out; } @@ -3763,7 +3763,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int *------------------------------------------------------------------------*/ sid_vlen_str_array = H5Screate_simple(STR_RANK, dims_vlen_str_array, NULL); if (sid_vlen_str_array < 0) { - fprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); status = FAIL; goto out; } @@ -3771,7 +3771,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int tid_vlen_str_array_pre = H5Tcopy(H5T_C_S1); status = H5Tset_size(tid_vlen_str_array_pre, H5T_VARIABLE); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); status = FAIL; goto out; } @@ -3779,7 +3779,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int /* Create the array data type for the string array */ tid_vlen_str_array = H5Tarray_create2(tid_vlen_str_array_pre, COMP_RANK, dims_vlen_str_array); if (tid_vlen_str_array < 0) { - fprintf(stderr, "Error: %s> H5Tarray_create2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tarray_create2 failed.\n", fname1); status = FAIL; goto out; } @@ -3789,7 +3789,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int *------------------------------------------------------------------------*/ sid_fixlen_str_array = H5Screate_simple(STR_RANK, dims_fixlen_str_array, NULL); if (sid_fixlen_str_array < 0) { - fprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); status = FAIL; goto out; } @@ -3797,14 +3797,14 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int tid_fixlen_str_array_pre = H5Tcopy(H5T_C_S1); status = H5Tset_size(tid_fixlen_str_array_pre, FIXLEN_STR_ARRY_SIZE); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tset_size failed.\n", fname1); status = FAIL; goto out; } /* Create the array data type for the string array */ tid_fixlen_str_array = H5Tarray_create2(tid_fixlen_str_array_pre, COMP_RANK, dims_fixlen_str_array); if (tid_fixlen_str_array < 0) { - fprintf(stderr, "Error: %s> H5Tarray_create2 failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Tarray_create2 failed.\n", fname1); status = FAIL; goto out; } @@ -3814,7 +3814,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int *------------------------------------------------------------------------*/ sid_comp = H5Screate_simple(COMP_RANK, dims_comp, NULL); if (sid_comp < 0) { - fprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Screate_simple failed.\n", fname1); status = FAIL; goto out; } @@ -3928,7 +3928,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset1", tid1_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid1_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp1_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3938,7 +3938,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset2", tid2_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid2_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp2_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3948,7 +3948,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset3", tid3_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid3_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp3_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3958,7 +3958,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset4", tid4_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid4_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp4_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3968,7 +3968,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset5", tid5_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid5_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp5_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3978,7 +3978,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset6", tid6_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid6_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp6_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3988,7 +3988,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset7", tid7_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid7_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp7_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -3998,7 +3998,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int did_comp = H5Dcreate2(gid, "Compound_dset8", tid8_comp, sid_comp, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); status = H5Dwrite(did_comp, tid8_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp8_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -4014,7 +4014,7 @@ static int test_comp_vlen_strings(const char *fname1, const char *grp_name, int status = H5Dwrite(did_comp, tid9_comp, H5S_ALL, H5S_ALL, H5P_DEFAULT, &comp9_buf); if (status < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", fname1); status = FAIL; goto out; } @@ -4136,14 +4136,14 @@ static int test_enums(const char *fname) enum_val = 0; status = H5Tenum_insert(tid, "YIN", &enum_val); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tenum_insert failed.\n", fname); + HDfprintf(stderr, "Error: %s> H5Tenum_insert failed.\n", fname); status = FAIL; goto out; } enum_val = 1; status = H5Tenum_insert(tid, "YANG", &enum_val); if (status < 0) { - fprintf(stderr, "Error: %s> H5Tenum_insert failed.\n", fname); + HDfprintf(stderr, "Error: %s> H5Tenum_insert failed.\n", fname); status = FAIL; goto out; } @@ -4154,13 +4154,13 @@ static int test_enums(const char *fname) status = write_dset(fid, 1, &dims, "dset1", tid, data1); if (status < 0) { - fprintf(stderr, "Error: %s> write_dset failed.\n", fname); + HDfprintf(stderr, "Error: %s> write_dset failed.\n", fname); status = FAIL; goto out; } status = write_dset(fid, 1, &dims, "dset2", tid, data2); if (status < 0) { - fprintf(stderr, "Error: %s> write_dset failed.\n", fname); + HDfprintf(stderr, "Error: %s> write_dset failed.\n", fname); status = FAIL; goto out; } @@ -4794,7 +4794,7 @@ static void test_data_nocomparables(const char * fname, int make_diffs) *------------------------------------------------------------------------*/ fid = H5Fcreate(fname, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname); status = FAIL; goto out; } @@ -4804,14 +4804,14 @@ static void test_data_nocomparables(const char * fname, int make_diffs) *------------------------------------------------------------------------*/ gid1 = H5Gcreate2(fid, "g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid1 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname); status = FAIL; goto out; } gid2 = H5Gcreate2(fid, "g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid2 < 0) { - fprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname); + HDfprintf(stderr, "Error: %s> H5Gcreate2 failed.\n", fname); status = FAIL; goto out; } @@ -4824,13 +4824,13 @@ static void test_data_nocomparables(const char * fname, int make_diffs) /* dset1 */ if ((did1 = H5Dcreate2(gid1, "dset1", tid_dset1, sid1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) { - fprintf(stderr, "Error: %s> H5Dcreate2 failed.\n", "dset1"); + HDfprintf(stderr, "Error: %s> H5Dcreate2 failed.\n", "dset1"); status = FAIL; goto out; } if (H5Dwrite(did1, tid_dset1, H5S_ALL, H5S_ALL, H5P_DEFAULT, dset_data_ptr1) < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", "dset1"); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", "dset1"); status = FAIL; goto out; } @@ -4839,7 +4839,7 @@ static void test_data_nocomparables(const char * fname, int make_diffs) /* dset2 */ status = write_dset(gid1, 1, dims1_1, "dset2", H5T_NATIVE_INT, dset_data_ptr2); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname); goto out; } @@ -4849,13 +4849,13 @@ static void test_data_nocomparables(const char * fname, int make_diffs) /* --------- * dset1 */ if ((did2 = H5Dcreate2(gid2, "dset1", H5T_NATIVE_INT, sid1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) { - fprintf(stderr, "Error: %s> H5Dcreate2 failed.\n", "dset1"); + HDfprintf(stderr, "Error: %s> H5Dcreate2 failed.\n", "dset1"); status = FAIL; goto out; } if (H5Dwrite(did2, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, dset_data_ptr3) < 0) { - fprintf(stderr, "Error: %s> H5Dwrite failed.\n", "dset1"); + HDfprintf(stderr, "Error: %s> H5Dwrite failed.\n", "dset1"); status = FAIL; goto out; } @@ -4875,7 +4875,7 @@ static void test_data_nocomparables(const char * fname, int make_diffs) * dset2 */ status = write_dset(gid2, 1, dims1_1, "dset2", H5T_NATIVE_INT, dset_data_ptr3); if (status == FAIL) { - fprintf(stderr, "Error: %s> write_dset failed\n", fname); + HDfprintf(stderr, "Error: %s> write_dset failed\n", fname); goto out; } @@ -5085,14 +5085,14 @@ static void test_objs_strings(const char *fname1, const char *fname2) /* file1 */ fid1 = H5Fcreate(fname1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid1 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname1); goto out; } /* file2 */ fid2 = H5Fcreate(fname2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fid2 < 0) { - fprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); + HDfprintf(stderr, "Error: %s> H5Fcreate failed.\n", fname2); goto out; } diff --git a/tools/test/h5dump/h5dumpgentest.c b/tools/test/h5dump/h5dumpgentest.c index 699a226..35c3e3c 100644 --- a/tools/test/h5dump/h5dumpgentest.c +++ b/tools/test/h5dump/h5dumpgentest.c @@ -563,7 +563,7 @@ gent_attribute(void) dims[0] = 24; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(root, "/attr1", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "attribute of root group"); + HDsprintf(buf, "attribute of root group"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); @@ -1373,7 +1373,7 @@ static void gent_all(void) dims[0] = 10; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(group, "attr1", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "abcdefghi"); + HDsprintf(buf, "abcdefghi"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); @@ -1404,7 +1404,7 @@ static void gent_all(void) dims[0] = 27; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(dataset, "attr1", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "1st attribute of dset1.1.1"); + HDsprintf(buf, "1st attribute of dset1.1.1"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); @@ -1412,7 +1412,7 @@ static void gent_all(void) dims[0] = 27; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(dataset, "attr2", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "2nd attribute of dset1.1.1"); + HDsprintf(buf, "2nd attribute of dset1.1.1"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); @@ -1608,7 +1608,7 @@ gent_many(void) dims[0] = 10; space2 = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(dataset, "attr1", H5T_STD_I8BE, space2, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "abcdefghi"); + HDsprintf(buf, "abcdefghi"); H5Awrite(attr, H5T_NATIVE_CHAR, buf); H5Sclose(space2); H5Aclose(attr); @@ -1927,9 +1927,9 @@ static void gent_str2(void) dims[0] = 3; space2 = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(dataset, "attr1", fxdlenstr2, space2, H5P_DEFAULT, H5P_DEFAULT); - sprintf(&(buf2[0*LENSTR2]), "0123456789"); - sprintf(&(buf2[1*LENSTR2]), "abcdefghij"); - sprintf(&(buf2[2*LENSTR2]), "ABCDEFGHIJ"); + HDsprintf(&(buf2[0*LENSTR2]), "0123456789"); + HDsprintf(&(buf2[1*LENSTR2]), "abcdefghij"); + HDsprintf(&(buf2[2*LENSTR2]), "ABCDEFGHIJ"); H5Awrite(attr, fxdlenstr2, buf2); H5Sclose(space2); H5Tclose(fxdlenstr2); @@ -1941,7 +1941,7 @@ static void gent_str2(void) for(i = 0; (hsize_t)i < sdim; i++) { start[0] = (hsize_t)i; - sprintf(buf, "This is row %1d of type H5T_STR_NULLTERM of", i); + HDsprintf(buf, "This is row %1d of type H5T_STR_NULLTERM of", i); H5Tset_size(memtype, HDstrlen(buf)+1); H5Sselect_hyperslab(hyper_space, H5S_SELECT_SET, start, stride, count, block); H5Dwrite(dataset, memtype, mem_space, hyper_space, H5P_DEFAULT, buf); @@ -1954,7 +1954,7 @@ static void gent_str2(void) for(i = 0; (hsize_t)i < sdim; i++) { start[0] = (hsize_t)i; - sprintf(buf, "This is row %1d of type H5T_STR_NULLTERM of string array", i); + HDsprintf(buf, "This is row %1d of type H5T_STR_NULLTERM of string array", i); H5Tset_size(memtype, HDstrlen(buf)+1); H5Sselect_hyperslab(hyper_space, H5S_SELECT_SET, start, stride, count, block); H5Dwrite(dataset, memtype, mem_space, hyper_space, H5P_DEFAULT, buf); @@ -1974,7 +1974,7 @@ static void gent_str2(void) for(i = 0;(hsize_t) i < sdim; i++) { start[0] = (hsize_t)i; - sprintf(buf, "This is row %1d of type H5T_STR_NULLPAD of", i); + HDsprintf(buf, "This is row %1d of type H5T_STR_NULLPAD of", i); H5Tset_size(memtype, HDstrlen(buf)+1); H5Sselect_hyperslab(hyper_space, H5S_SELECT_SET, start, stride, count, block); H5Dwrite(dataset, memtype, mem_space, hyper_space, H5P_DEFAULT, buf); @@ -1988,7 +1988,7 @@ static void gent_str2(void) for(i = 0; (hsize_t)i < sdim; i++) { start[0] = (hsize_t)i; - sprintf(buf, "This is row %1d of type H5T_STR_NULLPAD of string array", i); + HDsprintf(buf, "This is row %1d of type H5T_STR_NULLPAD of string array", i); H5Tset_size(memtype, HDstrlen(buf)+1); H5Sselect_hyperslab(hyper_space, H5S_SELECT_SET, start, stride, count, block); H5Dwrite(dataset, memtype, mem_space, hyper_space, H5P_DEFAULT, buf); @@ -2007,7 +2007,7 @@ static void gent_str2(void) for(i = 0; (hsize_t)i < sdim; i++) { start[0] = (hsize_t)i; - sprintf(buf, "This is row %1d of type H5T_STR_SPACEPAD of", i); + HDsprintf(buf, "This is row %1d of type H5T_STR_SPACEPAD of", i); H5Tset_size(memtype, HDstrlen(buf) + 1); H5Sselect_hyperslab(hyper_space, H5S_SELECT_SET, start, stride, count, block); H5Dwrite(dataset, memtype, mem_space, hyper_space, H5P_DEFAULT, buf); @@ -2021,7 +2021,7 @@ static void gent_str2(void) for(i = 0; (hsize_t)i < sdim; i++) { start[0] = (hsize_t)i; - sprintf(buf, "This is row %1d of type H5T_STR_SPACEPAD of string array", i); + HDsprintf(buf, "This is row %1d of type H5T_STR_SPACEPAD of string array", i); H5Tset_size(memtype, HDstrlen(buf) + 1); H5Sselect_hyperslab(hyper_space, H5S_SELECT_SET, start, stride, count, block); H5Dwrite(dataset, memtype, mem_space, hyper_space, H5P_DEFAULT, buf); @@ -2704,14 +2704,14 @@ gent_vldatatypes2(void) for(i = 0; i < SPACE1_DIM1; i++) { wdata[i].p = (hvl_t *)HDmalloc((i + 1) * sizeof(hvl_t)); if(wdata[i].p == NULL) { - printf("Cannot allocate memory for VL data! i=%u\n", i); + HDprintf("Cannot allocate memory for VL data! i=%u\n", i); return; } /* end if */ wdata[i].len = i + 1; for(t1 = (hvl_t *)wdata[i].p, j = 0; j < (i + 1); j++, t1++) { t1->p = (unsigned *)HDmalloc((j + 1) * sizeof(unsigned)); if(t1->p == NULL) { - printf("Cannot allocate memory for VL data! i=%u, j=%u\n",i,j); + HDprintf("Cannot allocate memory for VL data! i=%u, j=%u\n",i,j); return; } /* end if */ t1->len=j+1; @@ -3763,9 +3763,9 @@ void gent_multi(void) for(mt = H5FD_MEM_DEFAULT; mt < H5FD_MEM_NTYPES; H5_INC_ENUM(H5FD_mem_t,mt)) { memb_fapl[mt] = H5P_DEFAULT; memb_map[mt] = mt; - sprintf(sv[mt], "%%s-%c.h5", multi_letters[mt]); + HDsprintf(sv[mt], "%%s-%c.h5", multi_letters[mt]); memb_name[mt] = sv[mt]; - /*printf("memb_name[%d]=%s, memb_map[%d]=%d; ", mt, memb_name[mt], mt, memb_map[mt]);*/ + /*HDprintf("memb_name[%d]=%s, memb_map[%d]=%d; ", mt, memb_name[mt], mt, memb_map[mt]);*/ memb_addr[mt] = (haddr_t)MAX(mt - 1, 0) * (HADDR_MAX / 10); } memb_map[H5FD_MEM_DEFAULT] = H5FD_MEM_SUPER; @@ -3804,7 +3804,7 @@ static void gent_large_objname(void) group = H5Gcreate2(fid, "this_is_a_large_group_name", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); for(i = 0; i < 50; ++i) { - sprintf(grp_name, "this_is_a_large_group_name%d", i); + HDsprintf(grp_name, "this_is_a_large_group_name%d", i); group2 = H5Gcreate2(group, grp_name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); H5Gclose(group2); } @@ -6275,7 +6275,7 @@ static int gent_ldouble(void) return 0; error: - printf("error !\n"); + HDprintf("error !\n"); return -1; } @@ -6438,7 +6438,7 @@ gent_bigdims(void) return; out: - printf("Error.....\n"); + HDprintf("Error.....\n"); H5E_BEGIN_TRY { H5Pclose(dcpl); H5Sclose(f_sid); @@ -6630,7 +6630,7 @@ gent_group_creation_order(void) return; out: - printf("Error.....\n"); + HDprintf("Error.....\n"); H5E_BEGIN_TRY { H5Gclose(gid); H5Pclose(gcpl_id); @@ -6899,7 +6899,7 @@ gent_attr_creation_order(void) return; out: - printf("Error.....\n"); + HDprintf("Error.....\n"); H5E_BEGIN_TRY { H5Gclose(gid); H5Dclose(did); diff --git a/tools/test/h5import/h5importtest.c b/tools/test/h5import/h5importtest.c index bbb67b6..560f1b3 100644 --- a/tools/test/h5import/h5importtest.c +++ b/tools/test/h5import/h5importtest.c @@ -183,8 +183,8 @@ main(void) for (i = 0; i < nrow; i++) { for (j = 0; j < ncol; j++) - (void) fprintf(sp, "%10u", b8i3[k][i][j]); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "%10u", b8i3[k][i][j]); + (void) HDfprintf(sp, "\n"); } } (void) HDfclose(sp); @@ -200,8 +200,8 @@ main(void) for (i = 0; i < nrow; i++) { for (j = 0; j < ncol; j++) - (void) fprintf(sp, "%10u", b16i3[k][i][j]); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "%10u", b16i3[k][i][j]); + (void) HDfprintf(sp, "\n"); } } (void) HDfclose(sp); @@ -217,8 +217,8 @@ main(void) for (i = 0; i < nrow; i++) { for (j = 0; j < ncol; j++) - (void) fprintf(sp, "%10d", b32i3[k][i][j]); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "%10d", b32i3[k][i][j]); + (void) HDfprintf(sp, "\n"); } } (void) HDfclose(sp); @@ -243,16 +243,16 @@ main(void) (void) HDfclose(sp); sp = HDfopen("binin32.conf", "w"); - (void) fprintf(sp, "PATH /int/bin/32-bit\n"); - (void) fprintf(sp, "INPUT-CLASS IN\n"); - (void) fprintf(sp, "INPUT-SIZE 32\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 3\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER BE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 5 3 4\n"); - (void) fprintf(sp, "CHUNKED-DIMENSION-SIZES 1 2 1\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "PATH /int/bin/32-bit\n"); + (void) HDfprintf(sp, "INPUT-CLASS IN\n"); + (void) HDfprintf(sp, "INPUT-SIZE 32\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 3\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER BE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 5 3 4\n"); + (void) HDfprintf(sp, "CHUNKED-DIMENSION-SIZES 1 2 1\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); /*------------------------------------------------------------------------- @@ -274,15 +274,15 @@ main(void) (void) HDfclose(sp); sp = HDfopen("binuin32.conf", "w"); - (void) fprintf(sp, "PATH /int/buin/32-bit\n"); - (void) fprintf(sp, "INPUT-CLASS UIN\n"); - (void) fprintf(sp, "INPUT-SIZE 32\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 3\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 5 3 4\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "PATH /int/buin/32-bit\n"); + (void) HDfprintf(sp, "INPUT-CLASS UIN\n"); + (void) HDfprintf(sp, "INPUT-SIZE 32\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 3\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 5 3 4\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); /*------------------------------------------------------------------------- @@ -304,17 +304,17 @@ main(void) (void) HDfclose(sp); sp = HDfopen("binin16.conf", "w"); - (void) fprintf(sp, "PATH /int/bin/16-bit\n"); - (void) fprintf(sp, "INPUT-CLASS IN\n"); - (void) fprintf(sp, "INPUT-SIZE 16\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 3\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 2 3 4\n"); - (void) fprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); - (void) fprintf(sp, "MAXIMUM-DIMENSIONS -1 -1 8\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "PATH /int/bin/16-bit\n"); + (void) HDfprintf(sp, "INPUT-CLASS IN\n"); + (void) HDfprintf(sp, "INPUT-SIZE 16\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 3\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 2 3 4\n"); + (void) HDfprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); + (void) HDfprintf(sp, "MAXIMUM-DIMENSIONS -1 -1 8\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); /*------------------------------------------------------------------------- @@ -335,17 +335,17 @@ main(void) (void) HDfclose(sp); sp = HDfopen("binuin16.conf", "w"); - (void) fprintf(sp, "PATH /int/buin/16-bit\n"); - (void) fprintf(sp, "INPUT-CLASS UIN\n"); - (void) fprintf(sp, "INPUT-SIZE 16\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 3\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER BE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 2 3 4\n"); - (void) fprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); - (void) fprintf(sp, "MAXIMUM-DIMENSIONS -1 -1 8\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "PATH /int/buin/16-bit\n"); + (void) HDfprintf(sp, "INPUT-CLASS UIN\n"); + (void) HDfprintf(sp, "INPUT-SIZE 16\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 3\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER BE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 2 3 4\n"); + (void) HDfprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); + (void) HDfprintf(sp, "MAXIMUM-DIMENSIONS -1 -1 8\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); /*------------------------------------------------------------------------- @@ -367,20 +367,20 @@ main(void) (void) HDfclose(sp); sp = HDfopen("binin8.conf", "w"); - (void) fprintf(sp, "PATH /int/bin/8-bit\n"); - (void) fprintf(sp, "INPUT-CLASS IN\n"); - (void) fprintf(sp, "INPUT-SIZE 8\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 3\n"); - (void) fprintf(sp, "OUTPUT-CLASS IN\n"); - (void) fprintf(sp, "OUTPUT-SIZE 16\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 5 3 4\n"); - (void) fprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); - (void) fprintf(sp, "MAXIMUM-DIMENSIONS -1 -1 -1\n"); - (void) fprintf(sp, "COMPRESSION-PARAM 3\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "PATH /int/bin/8-bit\n"); + (void) HDfprintf(sp, "INPUT-CLASS IN\n"); + (void) HDfprintf(sp, "INPUT-SIZE 8\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 3\n"); + (void) HDfprintf(sp, "OUTPUT-CLASS IN\n"); + (void) HDfprintf(sp, "OUTPUT-SIZE 16\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 5 3 4\n"); + (void) HDfprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); + (void) HDfprintf(sp, "MAXIMUM-DIMENSIONS -1 -1 -1\n"); + (void) HDfprintf(sp, "COMPRESSION-PARAM 3\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); #endif /* UNICOS */ @@ -408,18 +408,18 @@ main(void) (void) HDfclose(sp); sp = HDfopen("binfp64.conf", "w"); - (void) fprintf(sp, "PATH /fp/bin/64-bit\n"); - (void) fprintf(sp, "INPUT-CLASS FP\n"); - (void) fprintf(sp, "INPUT-SIZE 64\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 3\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE IEEE\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 5 3 4\n"); - (void) fprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); - (void) fprintf(sp, "MAXIMUM-DIMENSIONS -1 6 7\n"); - (void) fprintf(sp, "COMPRESSION-PARAM 8\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "PATH /fp/bin/64-bit\n"); + (void) HDfprintf(sp, "INPUT-CLASS FP\n"); + (void) HDfprintf(sp, "INPUT-SIZE 64\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 3\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE IEEE\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 5 3 4\n"); + (void) HDfprintf(sp, "CHUNKED-DIMENSION-SIZES 2 2 2\n"); + (void) HDfprintf(sp, "MAXIMUM-DIMENSIONS -1 6 7\n"); + (void) HDfprintf(sp, "COMPRESSION-PARAM 8\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); /*------------------------------------------------------------------------- @@ -436,21 +436,21 @@ main(void) { char c = bin8w[i]; if ( HDfwrite( &c, sizeof(char), 1, sp) != 1 ) - printf("error writing file\n"); + HDprintf("error writing file\n"); } HDfclose(sp); sp = HDfopen("binin8w.conf", "w"); - (void) fprintf(sp, "INPUT-CLASS IN\n"); - (void) fprintf(sp, "INPUT-SIZE 8\n"); - (void) fprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); - (void) fprintf(sp, "RANK 1\n"); - (void) fprintf(sp, "OUTPUT-CLASS IN\n"); - (void) fprintf(sp, "OUTPUT-SIZE 8\n"); - (void) fprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); - (void) fprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); - (void) fprintf(sp, "DIMENSION-SIZES 4\n"); - (void) fprintf(sp, "\n"); + (void) HDfprintf(sp, "INPUT-CLASS IN\n"); + (void) HDfprintf(sp, "INPUT-SIZE 8\n"); + (void) HDfprintf(sp, "INPUT-BYTE-ORDER %s\n", machine_order); + (void) HDfprintf(sp, "RANK 1\n"); + (void) HDfprintf(sp, "OUTPUT-CLASS IN\n"); + (void) HDfprintf(sp, "OUTPUT-SIZE 8\n"); + (void) HDfprintf(sp, "OUTPUT-ARCHITECTURE STD\n"); + (void) HDfprintf(sp, "OUTPUT-BYTE-ORDER LE\n"); + (void) HDfprintf(sp, "DIMENSION-SIZES 4\n"); + (void) HDfprintf(sp, "\n"); (void) HDfclose(sp); } diff --git a/tools/test/h5jam/h5jamgentest.c b/tools/test/h5jam/h5jamgentest.c index 1644440..56b4ead 100644 --- a/tools/test/h5jam/h5jamgentest.c +++ b/tools/test/h5jam/h5jamgentest.c @@ -172,7 +172,7 @@ gent_ub(const char * filename, size_t ub_size, size_t ub_fill) dims[0] = 10; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(group, "attr1", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "abcdefghi"); + HDsprintf(buf, "abcdefghi"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); @@ -203,7 +203,7 @@ gent_ub(const char * filename, size_t ub_size, size_t ub_fill) dims[0] = 27; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(dataset, "attr1", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "1st attribute of dset1.1.1"); + HDsprintf(buf, "1st attribute of dset1.1.1"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); @@ -211,7 +211,7 @@ gent_ub(const char * filename, size_t ub_size, size_t ub_fill) dims[0] = 27; space = H5Screate_simple(1, dims, NULL); attr = H5Acreate2(dataset, "attr2", H5T_STD_I8BE, space, H5P_DEFAULT, H5P_DEFAULT); - sprintf(buf, "2nd attribute of dset1.1.1"); + HDsprintf(buf, "2nd attribute of dset1.1.1"); H5Awrite(attr, H5T_NATIVE_SCHAR, buf); H5Sclose(space); H5Aclose(attr); diff --git a/tools/test/h5repack/h5repacktst.c b/tools/test/h5repack/h5repacktst.c index a89bf10..057cbbd 100644 --- a/tools/test/h5repack/h5repacktst.c +++ b/tools/test/h5repack/h5repacktst.c @@ -3108,7 +3108,7 @@ int make_early(void) goto out; if ((tid = H5Tcopy(H5T_NATIVE_DOUBLE)) < 0) goto out; - sprintf(name, "%d", i); + HDsprintf(name, "%d", i); if ((H5Tcommit2(fid, name, tid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto out; if (H5Tclose(tid) < 0) @@ -3133,7 +3133,7 @@ int make_early(void) { if ((tid = H5Tcopy(H5T_NATIVE_DOUBLE)) < 0) goto out; - sprintf(name, "%d", i); + HDsprintf(name, "%d", i); if ((H5Tcommit2(fid, name, tid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto out; if (H5Tclose(tid) < 0) @@ -3195,7 +3195,7 @@ int make_layout(hid_t loc_id) */ for (i=0; i<4; i++) { - sprintf(name,"dset%d",i+1); + HDsprintf(name,"dset%d",i+1); if (write_dset(loc_id,RANK,dims,name,H5T_NATIVE_INT,buf) < 0) return -1; } @@ -6182,7 +6182,7 @@ static herr_t add_attr_with_objref(hid_t file_id, hid_t obj_id) status = H5Rcreate(&data_attr_objref[0],file_id,NAME_OBJ_DS1,H5R_OBJECT,(hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6191,7 +6191,7 @@ static herr_t add_attr_with_objref(hid_t file_id, hid_t obj_id) status = H5Rcreate(&data_attr_objref[1],file_id,NAME_OBJ_GRP,H5R_OBJECT,(hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6200,7 +6200,7 @@ static herr_t add_attr_with_objref(hid_t file_id, hid_t obj_id) status = H5Rcreate(&data_attr_objref[2],file_id,NAME_OBJ_NDTYPE,H5R_OBJECT,(hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6209,7 +6209,7 @@ static herr_t add_attr_with_objref(hid_t file_id, hid_t obj_id) status = make_attr(obj_id,1,dim_attr_objref,"Attr_OBJREF",H5T_STD_REF_OBJ,data_attr_objref); if (status < 0) { - fprintf(stderr, "Error: %s %d> make_attr failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> make_attr failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6251,7 +6251,7 @@ static herr_t add_attr_with_regref(hid_t file_id, hid_t obj_id) sid_regrefed_dset = H5Screate_simple (2, dim_regrefed_dset, NULL); if (sid_regrefed_dset < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6260,7 +6260,7 @@ static herr_t add_attr_with_regref(hid_t file_id, hid_t obj_id) status = H5Sselect_elements (sid_regrefed_dset, H5S_SELECT_SET, (size_t)3, coords_regrefed_dset[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6269,7 +6269,7 @@ static herr_t add_attr_with_regref(hid_t file_id, hid_t obj_id) status = H5Rcreate (&data_attr_regref[0], file_id, NAME_OBJ_DS2, H5R_DATASET_REGION, sid_regrefed_dset); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6278,7 +6278,7 @@ static herr_t add_attr_with_regref(hid_t file_id, hid_t obj_id) status = make_attr(obj_id,1,dim_attr_regref,"Attr_REGREF",H5T_STD_REF_DSETREG,data_attr_regref); if (status < 0) { - fprintf(stderr, "Error: %s %d> make_attr failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> make_attr failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6324,7 +6324,7 @@ static herr_t gen_refered_objs(hid_t loc_id) sid = H5Screate_simple(1, dims1, NULL); if (sid < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6332,7 +6332,7 @@ static herr_t gen_refered_objs(hid_t loc_id) did1 = H5Dcreate2 (loc_id, NAME_OBJ_DS1, H5T_NATIVE_INT, sid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (did1 < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6340,7 +6340,7 @@ static herr_t gen_refered_objs(hid_t loc_id) status = H5Dwrite(did1, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6352,7 +6352,7 @@ static herr_t gen_refered_objs(hid_t loc_id) gid = H5Gcreate2 (loc_id, NAME_OBJ_GRP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (gid < 0) { - fprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6365,7 +6365,7 @@ static herr_t gen_refered_objs(hid_t loc_id) status = H5Tcommit2(loc_id, NAME_OBJ_NDTYPE, tid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Tcommit2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Tcommit2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6378,7 +6378,7 @@ static herr_t gen_refered_objs(hid_t loc_id) sid2 = H5Screate_simple (2, dims2, NULL); if (sid2 < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6387,7 +6387,7 @@ static herr_t gen_refered_objs(hid_t loc_id) did2 = H5Dcreate2 (loc_id, NAME_OBJ_DS2, H5T_STD_I8LE, sid2, H5P_DEFAULT,H5P_DEFAULT,H5P_DEFAULT); if (did2 < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6396,7 +6396,7 @@ static herr_t gen_refered_objs(hid_t loc_id) status = H5Dwrite (did2, H5T_NATIVE_CHAR, H5S_ALL, H5S_ALL, H5P_DEFAULT, data2); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6453,7 +6453,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Rcreate (&objref_buf[0], loc_id, NAME_OBJ_DS1, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6462,7 +6462,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Rcreate (&objref_buf[1], loc_id, NAME_OBJ_GRP, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6471,7 +6471,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Rcreate (&objref_buf[2], loc_id, NAME_OBJ_NDTYPE, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6482,7 +6482,7 @@ static herr_t gen_obj_ref(hid_t loc_id) sid = H5Screate_simple (1, dims_dset_objref, NULL); if (sid < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6490,7 +6490,7 @@ static herr_t gen_obj_ref(hid_t loc_id) oid = H5Dcreate2 (loc_id, "Dset_OBJREF", H5T_STD_REF_OBJ, sid, H5P_DEFAULT,H5P_DEFAULT,H5P_DEFAULT); if (oid < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6498,7 +6498,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = H5Dwrite(oid, H5T_STD_REF_OBJ, H5S_ALL, H5S_ALL, H5P_DEFAULT, objref_buf); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6511,7 +6511,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = add_attr_with_objref(loc_id, oid); if (status < 0) { - fprintf(stderr, "Error: %s %d> add_attr_with_objref failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> add_attr_with_objref failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6520,7 +6520,7 @@ static herr_t gen_obj_ref(hid_t loc_id) status = add_attr_with_regref(loc_id, oid); if (status < 0) { - fprintf(stderr, "Error: %s %d> add_attr_with_regref failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> add_attr_with_regref failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6573,7 +6573,7 @@ static herr_t gen_region_ref(hid_t loc_id) sid_trg = H5Screate_simple (2, dims_trg, NULL); if (sid_trg < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6582,7 +6582,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Sselect_elements (sid_trg, H5S_SELECT_SET, (size_t)4, coords[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6591,7 +6591,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Rcreate (&rr_data[0], loc_id, NAME_OBJ_DS2, H5R_DATASET_REGION, sid_trg); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6600,7 +6600,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Sselect_hyperslab (sid_trg, H5S_SELECT_SET, start, stride, count, block); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_hyperslab failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_hyperslab failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6609,7 +6609,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Rcreate (&rr_data[1], loc_id, NAME_OBJ_DS2, H5R_DATASET_REGION, sid_trg); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6618,7 +6618,7 @@ static herr_t gen_region_ref(hid_t loc_id) sid_ref = H5Screate_simple (1, dims1, NULL); if (sid_ref < 0) { - fprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Screate_simple failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6627,7 +6627,7 @@ static herr_t gen_region_ref(hid_t loc_id) oid_ref = H5Dcreate2 (loc_id, REG_REF_DS1, H5T_STD_REF_DSETREG, sid_ref, H5P_DEFAULT,H5P_DEFAULT,H5P_DEFAULT); if (oid_ref < 0) { - fprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6636,7 +6636,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = H5Dwrite (oid_ref, H5T_STD_REF_DSETREG, H5S_ALL, H5S_ALL, H5P_DEFAULT, rr_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6649,7 +6649,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = add_attr_with_objref(loc_id, oid_ref); if (status < 0) { - fprintf(stderr, "Error: %s %d> add_attr_with_objref failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> add_attr_with_objref failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6658,7 +6658,7 @@ static herr_t gen_region_ref(hid_t loc_id) status = add_attr_with_regref(loc_id, oid_ref); if (status < 0) { - fprintf(stderr, "Error: %s %d> add_attr_with_regref failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> add_attr_with_regref failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6691,7 +6691,7 @@ static herr_t make_references(hid_t loc_id) status = gen_refered_objs(loc_id); if (status == FAIL) { - fprintf(stderr, "Failed to generate referenced object.\n"); + HDfprintf(stderr, "Failed to generate referenced object.\n"); ret = FAIL; } @@ -6699,7 +6699,7 @@ static herr_t make_references(hid_t loc_id) status = gen_obj_ref(loc_id); if (status == FAIL) { - fprintf(stderr, "Failed to generate object reference.\n"); + HDfprintf(stderr, "Failed to generate object reference.\n"); ret = FAIL; } @@ -6707,7 +6707,7 @@ static herr_t make_references(hid_t loc_id) status = gen_region_ref(loc_id); if (status == FAIL) { - fprintf(stderr, "Failed to generate region reference.\n"); + HDfprintf(stderr, "Failed to generate region reference.\n"); ret = FAIL; } @@ -6831,7 +6831,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Dwrite(objdid, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, obj_data[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6841,7 +6841,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Tcommit2(loc_id, NAME_OBJ_NDTYPE, objtid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Tcommit2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Tcommit2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6854,7 +6854,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) main_gid = H5Gcreate2(loc_id, "group_main", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT); if (main_gid < 0) { - fprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Gcreate2 failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6869,7 +6869,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Dwrite(main_did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, obj_data[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dwrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6893,7 +6893,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Rcreate (&(comp_objref_data[0].val_objref), loc_id, NAME_OBJ_DS1, H5R_OBJECT,(hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6903,7 +6903,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Rcreate (&(comp_objref_data[1].val_objref), loc_id, NAME_OBJ_GRP, H5R_OBJECT,(hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6913,7 +6913,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Rcreate (&(comp_objref_data[2].val_objref), loc_id, NAME_OBJ_NDTYPE, H5R_OBJECT,(hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6927,7 +6927,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Awrite (comp_objref_aid, comp_objref_tid, comp_objref_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6949,14 +6949,14 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Sselect_elements (objsid, H5S_SELECT_SET, (size_t)4, coords[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } status = H5Rcreate (&(comp_regref_data[0].val_regref), loc_id, NAME_OBJ_DS1, H5R_DATASET_REGION, objsid); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6970,7 +6970,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Awrite (comp_regref_aid, comp_regref_tid, comp_regref_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -6996,7 +6996,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Rcreate (&((hobj_ref_t*)vlen_objref_data[0].p)[0], loc_id, NAME_OBJ_DS1, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7004,7 +7004,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Rcreate (&((hobj_ref_t*)vlen_objref_data[1].p)[0], loc_id, NAME_OBJ_GRP, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7012,7 +7012,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Rcreate (&((hobj_ref_t*)vlen_objref_data[2].p)[0], loc_id, NAME_OBJ_NDTYPE, H5R_OBJECT, (hid_t)-1); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7030,7 +7030,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Awrite (vlen_objref_attr_id, vlen_objref_attr_tid, vlen_objref_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7039,7 +7039,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Dvlen_reclaim (vlen_objref_attr_tid, vlen_objref_attr_sid, H5P_DEFAULT, vlen_objref_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dvlen_reclaim failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dvlen_reclaim failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7060,14 +7060,14 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Sselect_elements(objsid, H5S_SELECT_SET, (size_t)4, coords[0]); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Sselect_elements failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } status = H5Rcreate (&((hdset_reg_ref_t*)vlen_regref_data[0].p)[0], loc_id, NAME_OBJ_DS1, H5R_DATASET_REGION, objsid); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Rcreate failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7085,7 +7085,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Awrite(vlen_regref_attr_id, vlen_regref_attr_tid, vlen_regref_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Awrite failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } @@ -7094,7 +7094,7 @@ static herr_t make_complex_attr_references(hid_t loc_id) status = H5Dvlen_reclaim (vlen_regref_attr_tid, vlen_regref_attr_sid, H5P_DEFAULT, vlen_regref_data); if (status < 0) { - fprintf(stderr, "Error: %s %d> H5Dvlen_reclaim failed.\n", FUNC, __LINE__); + HDfprintf(stderr, "Error: %s %d> H5Dvlen_reclaim failed.\n", FUNC, __LINE__); ret = FAIL; goto out; } diff --git a/tools/test/h5repack/testh5repack_detect_szip.c b/tools/test/h5repack/testh5repack_detect_szip.c index 6e7a24e..6b86dd5 100644 --- a/tools/test/h5repack/testh5repack_detect_szip.c +++ b/tools/test/h5repack/testh5repack_detect_szip.c @@ -50,10 +50,10 @@ int main(void) #ifdef H5_HAVE_FILTER_SZIP if (h5tools_can_encode(H5Z_FILTER_SZIP) == 1) { - printf("yes\n"); + HDprintf("yes\n"); return(1); } #endif /* H5_HAVE_FILTER_SZIP */ - printf("no\n"); + HDprintf("no\n"); return(0); } diff --git a/tools/test/h5stat/h5stat_gentest.c b/tools/test/h5stat/h5stat_gentest.c index ae11032..2edfcf6 100644 --- a/tools/test/h5stat/h5stat_gentest.c +++ b/tools/test/h5stat/h5stat_gentest.c @@ -88,7 +88,7 @@ gen_newgrat_file(const char *fname) /* Create NUM_GRPS groups in the root group */ for(i = 1; i <= NUM_GRPS; i++) { - sprintf(name, "%s%d", GROUP_NAME,i); + HDsprintf(name, "%s%d", GROUP_NAME,i); if((gid = H5Gcreate2(fid, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error; if(H5Gclose(gid) < 0) @@ -109,7 +109,7 @@ gen_newgrat_file(const char *fname) /* Create NUM_ATTRS for the dataset */ for(i = 1; i <= NUM_ATTRS; i++) { - sprintf(attrname, "%s%d", ATTR_NAME,i); + HDsprintf(attrname, "%s%d", ATTR_NAME,i); if((attr_id = H5Acreate2(did, attrname, tid, sid, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error; if(H5Aclose(attr_id) < 0) @@ -190,7 +190,7 @@ gen_threshold_file(const char *fname) /* Create 11 attributes for the dataset */ for(i = 1; i <= (THRES_NUM+1); i++) { - sprintf(name, "%s%d", THRES_ATTR_NAME,i); + HDsprintf(name, "%s%d", THRES_ATTR_NAME,i); if((attr_id = H5Acreate2(did, name, H5T_NATIVE_INT, sid1, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error; if(H5Aclose(attr_id) < 0) @@ -217,7 +217,7 @@ gen_threshold_file(const char *fname) /* Create 10 attributes for the 2-D dataset */ for(i = 1; i <= THRES_NUM; i++) { - sprintf(name, "%s%d", THRES_ATTR_NAME,i); + HDsprintf(name, "%s%d", THRES_ATTR_NAME,i); if((attr_id = H5Acreate2(did, name, H5T_NATIVE_INT, sid1, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error; if(H5Aclose(attr_id) < 0) @@ -241,7 +241,7 @@ gen_threshold_file(const char *fname) /* Create 10 1-D datasets with non-zero dimension size for the group */ for(i = 1; i <= THRES_NUM; i++) { /* set up dataset name */ - sprintf(name, "%s%d", THRES_DSET_NAME,i); + HDsprintf(name, "%s%d", THRES_DSET_NAME,i); /* Create the dataset */ if((did = H5Dcreate2(gid, name, H5T_NATIVE_UCHAR, sid1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) @@ -264,7 +264,7 @@ gen_threshold_file(const char *fname) /* Create 25 attributes for the group */ for(i = 1; i <= THRES_NUM_25; i++) { /* Set up attribute name */ - sprintf(name, "%s%d", THRES_ATTR_GRP_NAME,i); + HDsprintf(name, "%s%d", THRES_ATTR_GRP_NAME,i); /* Create the attribute */ if((attr_id = H5Acreate2(gid, name, H5T_NATIVE_INT, sid2, H5P_DEFAULT, H5P_DEFAULT)) < 0) @@ -286,7 +286,7 @@ gen_threshold_file(const char *fname) /* Create 9 1-D datasets with non-zero dimension size for the group */ for(i = 1; i < THRES_NUM; i++) { /* set up dataset name */ - sprintf(name, "%s%d", THRES_DSET_NAME,i); + HDsprintf(name, "%s%d", THRES_DSET_NAME,i); /* Create the dataset */ if((did = H5Dcreate2(gid, name, H5T_NATIVE_UCHAR, sid1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) diff --git a/tools/test/misc/h5clear_gentest.c b/tools/test/misc/h5clear_gentest.c index 7f80c23..96d7e75e7 100644 --- a/tools/test/misc/h5clear_gentest.c +++ b/tools/test/misc/h5clear_gentest.c @@ -15,10 +15,10 @@ /* The HDF5 test files */ const char *FILENAME[] = { - "h5clear_sec2_v3.h5", /* 0 -- sec2 file with superblock version 3 */ - "h5clear_log_v3.h5", /* 1 -- log file with superblock veresion 3 */ - "h5clear_sec2_v0.h5", /* 2 -- sec2 file with superblock version 0 */ - "h5clear_sec2_v2.h5" /* 3 -- sec2 file with superblock version 2 */ + "h5clear_sec2_v3.h5", /* 0 -- sec2 file with superblock version 3 */ + "h5clear_log_v3.h5", /* 1 -- log file with superblock veresion 3 */ + "h5clear_sec2_v0.h5", /* 2 -- sec2 file with superblock version 0 */ + "h5clear_sec2_v2.h5" /* 3 -- sec2 file with superblock version 2 */ }; const char *FILENAME_ENHANCE[] = { @@ -28,12 +28,12 @@ const char *FILENAME_ENHANCE[] = { "h5clear_fsm_persist_user_equal.h5", /* 3: user block, persisting free-space, stored EOA = actual EOF */ "h5clear_fsm_persist_user_greater.h5", /* 4: user block, persisting free-space, stored EOA > actual EOF */ "h5clear_fsm_persist_user_less.h5", /* 5: user block, persisting free-space, stored EOA < actual EOF */ - "h5clear_status_noclose.h5", /* 6 -- v3 superblock, nonzero status_flags, no flush, exit, + "h5clear_status_noclose.h5", /* 6 -- v3 superblock, nonzero status_flags, no flush, exit, stored EOA < actual EOF */ "h5clear_fsm_persist_noclose.h5" /* 7 -- persisting free-space, no flush, exit, stored EOA < actual EOF */ }; -#define KB 1024U +#define KB 1024U #define CACHE_IMAGE_FILE "h5clear_mdc_image.h5" #define DSET "DSET" @@ -42,14 +42,14 @@ const char *FILENAME_ENHANCE[] = { #define USERBLOCK 512 /*------------------------------------------------------------------------- - * Function: gen_cache_image_file + * Function: gen_cache_image_file * - * Purpose: To create a file with cache image feature enabled. + * Purpose: To create a file with cache image feature enabled. * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Vailin Choi; March 2017 + * Programmer: Vailin Choi; March 2017 * *------------------------------------------------------------------------- */ @@ -136,9 +136,9 @@ error: } /* gen_cache_image_file() */ /*------------------------------------------------------------------------- - * Function: gen_enhance_files + * Function: gen_enhance_files * - * Purpose: To create the first 6 files in FILENAME_ENHANCE[]: + * Purpose: To create the first 6 files in FILENAME_ENHANCE[]: * (0) FILENAME_ENHANCE[0]: "h5clear_fsm_persist_equal.h5" * (1) FILENAME_ENHANCE[1]: "h5clear_fsm_persist_greater.h5" * (2) FILENAME_ENHANCE[2]: "h5clear_fsm_persist_less.h5" @@ -149,15 +149,15 @@ error: * value to the location where the EOA is stored in the superblock. * Also modify the chksum in the superblock due to this change. * - * The first call to this routine (without user block) will generate + * The first call to this routine (without user block) will generate * the first 3 files. * The second call to this routine (with user block) will generate * the last 3 files. * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Vailin Choi; March 2017 + * Programmer: Vailin Choi; March 2017 * *------------------------------------------------------------------------- */ @@ -190,7 +190,7 @@ gen_enhance_files(hbool_t user) if(H5Pset_file_space_strategy(fcpl, H5F_FSPACE_STRATEGY_FSM_AGGR, TRUE, (hsize_t)1) < 0) goto error; - /* + /* * Create the file, then write invalid EOA to the file. */ for(i = 0+u; i < 3+u; i++) { @@ -221,21 +221,21 @@ gen_enhance_files(hbool_t user) if(H5Fclose(fid) < 0) goto error; - /* + /* * No further action for: - * --FILENAME_ENHANCE[0]: "h5clear_fsm_persist_equal.h5" + * --FILENAME_ENHANCE[0]: "h5clear_fsm_persist_equal.h5" * --FILENAME_ENHANCE[3]: "h5clear_fsm_persist_user_equal.h5", */ if(!(i % 3)) continue; - /* + /* * For the following files: * --FILENAME_ENHANCE[1]: "h5clear_fsm_persist_greater.h5" * --FILENAME_ENHANCE[2]: "h5clear_fsm_persist_less.h5" * --FILENAME_ENHANCE[4]: "h5clear_fsm_persist_greater.h5" * --FILENAME_ENHANCE[5]: "h5clear_fsm_persist_less.h5" * - * Write invalid value to the location for stored eoa and + * Write invalid value to the location for stored eoa and * update the chksum value. */ /* Open the file */ @@ -306,9 +306,9 @@ error: } /* gen_enhance_files() */ /*------------------------------------------------------------------------- - * Function: main + * Function: main * - * Purpose: Generate test files used by h5clear. + * Purpose: Generate test files used by h5clear. * * (A) gen_cache_image_file(): * --generate a file with cache image feature @@ -317,10 +317,10 @@ error: * --generate the first 6 files in FILENAME_ENHANCE[]: * (0) "h5clear_fsm_persist_equal.h5" * (1) "h5clear_fsm_persist_greater.h5" - * (2) "h5clear_fsm_persist_less.h5" - * (3) "h5clear_fsm_persist_user_equal.h5" + * (2) "h5clear_fsm_persist_less.h5" + * (3) "h5clear_fsm_persist_user_equal.h5" * (4) "h5clear_fsm_persist_user_greater.h5" - * (5) "h5clear_fsm_persist_user_less.h5" + * (5) "h5clear_fsm_persist_user_less.h5" * * (C) Generate the following FILENAME[] files in main(): * (0a) "h5clear_sec2_v3.h5" @@ -328,43 +328,43 @@ error: * (1a) "h5clear_log_v3.h5", * (1b) "latest_h5clear_log_v3.h5" * (2) "h5clear_sec2_v0.h5" - * (3) "h5clear_sec2_v2.h5" - * - * These HDF5 files are created with non-zero status_flags in + * (3) "h5clear_sec2_v2.h5" + * + * These HDF5 files are created with non-zero status_flags in * the superblock via flushing and exiting without closing the * library. - * Due to file locking, status_flags in the superblock will be - * nonzero after H5Fcreate. The library will clear status_flags - * on file closing. + * Due to file locking, status_flags in the superblock will be + * nonzero after H5Fcreate. The library will clear status_flags + * on file closing. * This program, after "H5Fcreate" the files, exits without - * going through library closing. Thus, status_flags for these - * files are not cleared. - * The library will check consistency of status_flags when - * opening a file with superblock >= v3 and will return error + * going through library closing. Thus, status_flags for these + * files are not cleared. + * The library will check consistency of status_flags when + * opening a file with superblock >= v3 and will return error * accordingly. - * The library will not check status_flags when opening a file - * with < v3 superblock. - * These files are used by "h5clear" to see if the tool clears - * status_flags properly so users can open the files afterwards. - * + * The library will not check status_flags when opening a file + * with < v3 superblock. + * These files are used by "h5clear" to see if the tool clears + * status_flags properly so users can open the files afterwards. + * * (D) Generate the last two files in FILENAME_ENHANCE[] in main(): - * (6) "h5clear_status_noclose.h5", + * (6) "h5clear_status_noclose.h5", * (7) "h5clear_fsm_persist_noclose.h5" * - * Return: Success: 0 - * Failure: 1 + * Return: Success: 0 + * Failure: 1 * - * Programmer: Vailin Choi; July 2013 + * Programmer: Vailin Choi; July 2013 * *------------------------------------------------------------------------- */ int main(void) { - hid_t fid = -1; /* File ID */ - hid_t fcpl = -1; /* File creation property list */ - hid_t fapl = -1, new_fapl = -1; /* File access property lists */ - char fname[512]; /* File name */ + hid_t fid = -1; /* File ID */ + hid_t fcpl = -1; /* File creation property list */ + hid_t fapl = -1, new_fapl = -1; /* File access property lists */ + char fname[512]; /* File name */ unsigned new_format; /* To use latest library format or not */ hid_t sid = -1; /* Dataspace ID */ hid_t did = -1; /* Dataset ID */ @@ -382,7 +382,7 @@ main(void) if(gen_enhance_files(TRUE) < 0) goto error; - /* + /* * Generate files in FILENAME[] */ /* Create a copy of the file access property list */ @@ -396,13 +396,13 @@ main(void) if(H5Pset_libver_bounds(new_fapl, H5F_LIBVER_LATEST, H5F_LIBVER_LATEST) < 0) goto error; - /* + /* * Files created within this for loop will have v3 superblock and nonzero status_flags * --FILENAME[0]: "h5clear_sec2_v3.h5", "latest_h5clear_sec2_v3.h5" * --FILENAME[1]: "h5clear_log_v3.h5", "latest_h5clear_log_v3.h5" */ for(new_format = FALSE; new_format <= TRUE; new_format++) { - hid_t fapl2, my_fapl; /* File access property lists */ + hid_t fapl2, my_fapl; /* File access property lists */ /* Set to use the appropriate file access property list */ if(new_format) @@ -415,14 +415,14 @@ main(void) if((my_fapl = H5Pcopy(fapl2)) < 0) goto error; /* Create the file */ - sprintf(fname, "%s%s", new_format? "latest_":"", FILENAME[0]); - if((fid = H5Fcreate(fname, H5F_ACC_TRUNC | (new_format ? 0 : H5F_ACC_SWMR_WRITE), H5P_DEFAULT, my_fapl)) < 0) + HDsprintf(fname, "%s%s", new_format? "latest_":"", FILENAME[0]); + if((fid = H5Fcreate(fname, H5F_ACC_TRUNC | (new_format ? 0 : H5F_ACC_SWMR_WRITE), H5P_DEFAULT, my_fapl)) < 0) goto error; /* Flush the file */ if(H5Fflush(fid, H5F_SCOPE_GLOBAL) < 0) goto error; - + /* Close the property list */ if(H5Pclose(my_fapl) < 0) goto error; @@ -439,8 +439,8 @@ main(void) goto error; /* Create the file */ - sprintf(fname, "%s%s", new_format? "latest_":"", FILENAME[1]); - if((fid = H5Fcreate(fname, H5F_ACC_TRUNC | (new_format ? 0 : H5F_ACC_SWMR_WRITE), H5P_DEFAULT, my_fapl)) < 0) + HDsprintf(fname, "%s%s", new_format? "latest_":"", FILENAME[1]); + if((fid = H5Fcreate(fname, H5F_ACC_TRUNC | (new_format ? 0 : H5F_ACC_SWMR_WRITE), H5P_DEFAULT, my_fapl)) < 0) goto error; /* Flush the file */ @@ -453,11 +453,11 @@ main(void) } /* end for */ - /* + /* * Create a sec2 file with v0 superblock but nonzero status_flags: * FILENAME[2]: "h5clear_sec2_v0.h5" */ - if((fid = H5Fcreate(FILENAME[2], H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) + if((fid = H5Fcreate(FILENAME[2], H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) goto error; /* Flush the file */ @@ -465,9 +465,9 @@ main(void) goto error; - /* + /* * Create a sec2 file with v2 superblock but nonzero status_flags: - * FILENAME[3]: "h5clear_sec2_v2.h5" + * FILENAME[3]: "h5clear_sec2_v2.h5" */ if((fcpl = H5Pcreate(H5P_FILE_CREATE)) < 0) goto error; @@ -476,14 +476,14 @@ main(void) if(H5Pset_shared_mesg_index(fcpl, 0, H5O_SHMESG_DTYPE_FLAG, 50) < 0) goto error; - if((fid = H5Fcreate(FILENAME[3], H5F_ACC_TRUNC, fcpl, fapl)) < 0) + if((fid = H5Fcreate(FILENAME[3], H5F_ACC_TRUNC, fcpl, fapl)) < 0) goto error; /* Flush the file */ if(H5Fflush(fid, H5F_SCOPE_GLOBAL) < 0) goto error; - + /* Close the property lists */ if(H5Pclose(fapl) < 0) goto error; @@ -492,10 +492,10 @@ main(void) if(H5Pclose(fcpl) < 0) goto error; - /* + /* * Create the last two files in FILENAME_ENHANCE[]: * --FILENAME_ENHANCE[6]: h5clear_status_noclose.h5 - * --FILENAME_ENHANCE[7]: h5clear_fsm_persist_noclose.h5 + * --FILENAME_ENHANCE[7]: h5clear_fsm_persist_noclose.h5 */ /* * FILENAME_ENHANCE[6]: h5clear_status_noclose.h5 @@ -503,7 +503,7 @@ main(void) * --version 3 superblock * --nonzero status_flags * --does not persist free-space - * --does not flush the file, just exit without closing file: + * --does not flush the file, just exit without closing file: * --this file is similar to the user-suppplied test file attached with HDFFV-10347 */ if((fapl = H5Pcreate(H5P_FILE_ACCESS)) < 0) @@ -542,8 +542,8 @@ main(void) /* Does not flush and does not close the file */ - /* - * FILENAME_ENHANCE[7]: h5clear_fsm_persist_noclose.h5 + /* + * FILENAME_ENHANCE[7]: h5clear_fsm_persist_noclose.h5 * --stored EOA < actual EOF * --persisting free-space * --undefined fsinfo.eoa_pre_fsm_fsalloc diff --git a/tools/test/misc/talign.c b/tools/test/misc/talign.c index 08ebfc7..7f1f038 100644 --- a/tools/test/misc/talign.c +++ b/tools/test/misc/talign.c @@ -51,14 +51,14 @@ int main(void) int result = 0; herr_t error = 1; - printf("%-70s", "Testing alignment in compound datatypes"); + HDprintf("%-70s", "Testing alignment in compound datatypes"); - strcpy(string5, "Hi!"); + HDstrcpy(string5, "Hi!"); HDunlink(fname); fil = H5Fcreate(fname, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); if (fil < 0) { - puts("*FAILED*"); + HDputs("*FAILED*"); return 1; } @@ -123,8 +123,8 @@ int main(void) data = (char *)HDmalloc(H5Tget_size(fix)); if(!data) { - perror("malloc() failed"); - abort(); + HDperror("malloc() failed"); + HDabort(); } set = H5Dopen2(fil, setname, H5P_DEFAULT); @@ -136,7 +136,7 @@ int main(void) out: if(error < 0) { result = 1; - puts("*FAILED - HDF5 library error*"); + HDputs("*FAILED - HDF5 library error*"); } else if(!(H5_FLT_ABS_EQUAL(fok[0], fptr[0])) || !(H5_FLT_ABS_EQUAL(fok[1], fptr[1])) || !(H5_FLT_ABS_EQUAL(fnok[0], fptr[2])) @@ -145,7 +145,7 @@ out: result = 1; mname = H5Tget_member_name(fix, 0); - printf("%14s (%2d) %6s = %s\n", + HDprintf("%14s (%2d) %6s = %s\n", mname ? mname : "(null)", (int)H5Tget_member_offset(fix,0), string5, (char *)(data + H5Tget_member_offset(fix, 0))); if(mname) @@ -153,7 +153,7 @@ out: fptr = (float *)((void *)(data + H5Tget_member_offset(fix, 1))); mname = H5Tget_member_name(fix, 1); - printf("Data comparison:\n" + HDprintf("Data comparison:\n" "%14s (%2d) %6f = %f\n" " %6f = %f\n", mname ? mname : "(null)", (int)H5Tget_member_offset(fix,1), @@ -164,7 +164,7 @@ out: fptr = (float *)((void *)(data + H5Tget_member_offset(fix, 2))); mname = H5Tget_member_name(fix, 2); - printf("%14s (%2d) %6f = %f\n" + HDprintf("%14s (%2d) %6f = %f\n" " %6f = %6f\n", mname ? mname : "(null)", (int)H5Tget_member_offset(fix,2), (double)fnok[0], (double)fptr[0], @@ -173,7 +173,7 @@ out: H5free_memory(mname); fptr = (float *)((void *)(data + H5Tget_member_offset(fix, 1))); - printf("\n" + HDprintf("\n" "Short circuit\n" " %6f = %f\n" " %6f = %f\n" @@ -183,9 +183,9 @@ out: (double)fok[1], (double)fptr[1], (double)fnok[0], (double)fptr[2], (double)fnok[1], (double)fptr[3]); - puts("*FAILED - compound type alignmnent problem*"); + HDputs("*FAILED - compound type alignmnent problem*"); } else { - puts(" PASSED"); + HDputs(" PASSED"); } if(data) @@ -200,7 +200,7 @@ out: H5Pclose(plist); H5Fclose(fil); HDunlink(fname); - fflush(stdout); + HDfflush(stdout); return result; } |