summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/big.c2
-rw-r--r--test/dangle.c7
-rw-r--r--test/dsets.c4
-rw-r--r--test/enum.c278
-rw-r--r--test/external.c38
-rw-r--r--test/flush1.c33
-rw-r--r--test/gen_mergemsg.c6
-rw-r--r--test/gen_new_group.c4
-rw-r--r--test/gen_old_group.c2
-rw-r--r--test/gen_udlinks.c4
-rw-r--r--test/getname.c281
-rw-r--r--test/h5test.c8
-rw-r--r--test/links.c226
-rw-r--r--test/mount.c165
-rw-r--r--test/ntypes.c3
-rwxr-xr-xtest/objcopy.c152
-rw-r--r--test/stab.c214
-rw-r--r--test/tattr.c16
-rw-r--r--test/testmeta.c12
-rw-r--r--test/tfile.c34
-rw-r--r--test/th5o.c16
-rw-r--r--test/titerate.c20
-rw-r--r--test/tmisc.c66
-rw-r--r--test/trefer.c16
-rw-r--r--test/tsohm.c16
-rw-r--r--test/tunicode.c20
-rw-r--r--test/tvltypes.c12
-rw-r--r--test/unlink.c89
28 files changed, 892 insertions, 852 deletions
diff --git a/test/big.c b/test/big.c
index 5481cd0..f75a6f3 100644
--- a/test/big.c
+++ b/test/big.c
@@ -33,7 +33,7 @@ const char *FILENAME[] = {
#define FAMILY_SIZE 1024*1024*1024
/* Define big file as 2GB */
-#define BIG_FILE 0x80000000UL
+#define BIG_FILE (off_t)0x80000000UL
#define MAX_TRIES 100
diff --git a/test/dangle.c b/test/dangle.c
index 9b5d0dd..4e1154a 100644
--- a/test/dangle.c
+++ b/test/dangle.c
@@ -174,17 +174,16 @@ test_dangle_group(H5F_close_degree_t degree)
if((fid = H5Fcreate (filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0)
TEST_ERROR;
- if((gid = H5Gcreate (fid, GROUPNAME, 0))<0)
- TEST_ERROR;
+ if((gid = H5Gcreate2(fid, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
if(H5Gclose(gid)<0)
TEST_ERROR;
/* Try creating duplicate group */
H5E_BEGIN_TRY {
- if((gid = H5Gcreate (fid, GROUPNAME, 0))>=0)
- TEST_ERROR;
+ gid = H5Gcreate2(fid, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
+ if(gid >= 0) TEST_ERROR
/* Leave open a _lot_ of objects */
for(u=0; u<MAX_DANGLE; u++) {
diff --git a/test/dsets.c b/test/dsets.c
index 4242a26..d1c6e17 100644
--- a/test/dsets.c
+++ b/test/dsets.c
@@ -4690,7 +4690,7 @@ test_types(hid_t file)
unsigned char buf[32];
TESTING("various datatypes");
- if((grp = H5Gcreate(file, "typetests", (size_t)0)) < 0) goto error;
+ if((grp = H5Gcreate2(file, "typetests", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
/* bitfield_1 */
nelmts = sizeof(buf);
@@ -6271,7 +6271,7 @@ main(void)
goto error;
/* Cause the library to emit initial messages */
- if((grp = H5Gcreate(file, "emit diagnostics", (size_t)0)) < 0)
+ if((grp = H5Gcreate2(file, "emit diagnostics", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
goto error;
if(H5Gset_comment(grp, ".", "Causes diagnostic messages to be emitted") < 0)
goto error;
diff --git a/test/enum.c b/test/enum.c
index 7574e40..5f73969 100644
--- a/test/enum.c
+++ b/test/enum.c
@@ -53,48 +53,49 @@ typedef enum {
static int
test_named(hid_t file)
{
- hid_t type=-1, cwg=-1;
+ hid_t type = -1, cwg = -1;
c_e1 val;
signed char val8;
TESTING("named enumeration types");
- if ((cwg=H5Gcreate(file, "test_named", 0))<0) goto error;
+ if((cwg = H5Gcreate2(file, "test_named", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* A native integer */
- if ((type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(type, "RED", CPTR(val, E1_RED ))<0) goto error;
- if (H5Tenum_insert(type, "GREEN", CPTR(val, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(type, "BLUE", CPTR(val, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(type, "WHITE", CPTR(val, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(type, "BLACK", CPTR(val, E1_BLACK))<0) goto error;
- if (H5Tcommit(cwg, "e1_a", type)<0) goto error;
- if (H5Tclose(type)<0) goto error;
+ if((type = H5Tcreate(H5T_ENUM, sizeof(c_e1))) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "RED", CPTR(val, E1_RED )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "GREEN", CPTR(val, E1_GREEN)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLUE", CPTR(val, E1_BLUE )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "WHITE", CPTR(val, E1_WHITE)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLACK", CPTR(val, E1_BLACK)) < 0) FAIL_STACK_ERROR
+ if(H5Tcommit(cwg, "e1_a", type) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(type) < 0) FAIL_STACK_ERROR
/* A smaller type */
- if ((type = H5Tcreate(H5T_ENUM, 1))<0) goto error;
- if (H5Tenum_insert(type, "RED", CPTR(val8, E1_RED ))<0) goto error;
- if (H5Tenum_insert(type, "GREEN", CPTR(val8, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(type, "BLUE", CPTR(val8, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(type, "WHITE", CPTR(val8, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(type, "BLACK", CPTR(val8, E1_BLACK))<0) goto error;
- if (H5Tcommit(cwg, "e1_b", type)<0) goto error;
- if (H5Tclose(type)<0) goto error;
+ if((type = H5Tcreate(H5T_ENUM, 1)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "RED", CPTR(val8, E1_RED )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "GREEN", CPTR(val8, E1_GREEN)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLUE", CPTR(val8, E1_BLUE )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "WHITE", CPTR(val8, E1_WHITE)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLACK", CPTR(val8, E1_BLACK)) < 0) FAIL_STACK_ERROR
+ if(H5Tcommit(cwg, "e1_b", type) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(type) < 0) FAIL_STACK_ERROR
/* A non-native type */
- if (H5T_ORDER_BE==H5Tget_order(H5T_NATIVE_INT)) {
- if ((type = H5Tenum_create(H5T_STD_U8LE))<0) goto error;
+ if(H5T_ORDER_BE == H5Tget_order(H5T_NATIVE_INT)) {
+ if ((type = H5Tenum_create(H5T_STD_U8LE)) < 0) FAIL_STACK_ERROR
} else {
- if ((type = H5Tenum_create(H5T_STD_U8BE))<0) goto error;
+ if ((type = H5Tenum_create(H5T_STD_U8BE)) < 0) FAIL_STACK_ERROR
}
- if (H5Tenum_insert(type, "RED", CPTR(val8, E1_RED ))<0) goto error;
- if (H5Tenum_insert(type, "GREEN", CPTR(val8, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(type, "BLUE", CPTR(val8, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(type, "WHITE", CPTR(val8, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(type, "BLACK", CPTR(val8, E1_BLACK))<0) goto error;
- if (H5Tcommit(cwg, "e1_c", type)<0) goto error;
- if (H5Tclose(type)<0) goto error;
+ if(H5Tenum_insert(type, "RED", CPTR(val8, E1_RED )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "GREEN", CPTR(val8, E1_GREEN)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLUE", CPTR(val8, E1_BLUE )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "WHITE", CPTR(val8, E1_WHITE)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLACK", CPTR(val8, E1_BLACK)) < 0) FAIL_STACK_ERROR
+ if(H5Tcommit(cwg, "e1_c", type) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(type) < 0) FAIL_STACK_ERROR
+
+ if(H5Gclose(cwg) < 0) FAIL_STACK_ERROR
- if (H5Gclose(cwg)<0) goto error;
PASSED();
return 0;
@@ -137,35 +138,35 @@ test_noconv(hid_t file)
size_t i;
TESTING("no-conversion datasets");
- if ((cwg=H5Gcreate(file, "test_noconv", 0))<0) goto error;
- if ((type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(type, "RED", CPTR(val, E1_RED ))<0) goto error;
- if (H5Tenum_insert(type, "GREEN", CPTR(val, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(type, "BLUE", CPTR(val, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(type, "WHITE", CPTR(val, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(type, "BLACK", CPTR(val, E1_BLACK))<0) goto error;
+ if((cwg = H5Gcreate2(file, "test_noconv", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
- if ((space=H5Screate_simple(1, ds_size, NULL))<0) goto error;
- if ((dset=H5Dcreate(cwg, "color_table", type, space, H5P_DEFAULT))<0)
- goto error;
- if (H5Dwrite(dset, type, space, space, H5P_DEFAULT, data1)<0) goto error;
- if (H5Dread(dset, type, space, space, H5P_DEFAULT, data2)<0) goto error;
+ if((type = H5Tcreate(H5T_ENUM, sizeof(c_e1))) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "RED", CPTR(val, E1_RED )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "GREEN", CPTR(val, E1_GREEN)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLUE", CPTR(val, E1_BLUE )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "WHITE", CPTR(val, E1_WHITE)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(type, "BLACK", CPTR(val, E1_BLACK)) < 0) FAIL_STACK_ERROR
- for (i=0; i<(size_t)ds_size[0]; i++) {
- if (data1[i]!=data2[i]) {
+ if((space=H5Screate_simple(1, ds_size, NULL)) < 0) FAIL_STACK_ERROR
+ if((dset=H5Dcreate(cwg, "color_table", type, space, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Dwrite(dset, type, space, space, H5P_DEFAULT, data1) < 0) FAIL_STACK_ERROR
+ if(H5Dread(dset, type, space, space, H5P_DEFAULT, data2) < 0) FAIL_STACK_ERROR
+
+ for(i = 0; i < (size_t)ds_size[0]; i++)
+ if(data1[i] != data2[i]) {
H5_FAILED();
printf(" data1[%lu]=%d, data2[%lu]=%d (should be same)\n",
(unsigned long)i, (int)(data1[i]),
(unsigned long)i, (int)(data2[i]));
goto error;
- }
- }
+ } /* end if */
+
+ if(H5Dclose(dset) < 0) FAIL_STACK_ERROR
+ if(H5Sclose(space) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(type) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(cwg) < 0) FAIL_STACK_ERROR
- if (H5Dclose(dset)<0) goto error;
- if (H5Sclose(space)<0) goto error;
- if (H5Tclose(type)<0) goto error;
- if (H5Gclose(cwg)<0) goto error;
PASSED();
return 0;
@@ -202,76 +203,77 @@ test_noconv(hid_t file)
static int
test_tr1(hid_t file)
{
- hid_t cwg=-1, m_type=-1, f_type=-1, space=-1, dset=-1;
- hsize_t ds_size[1]={10};
+ hid_t cwg = -1, m_type = -1, f_type = -1, space = -1, dset = -1;
+ hsize_t ds_size[1] = {10};
size_t i;
c_e1 eval;
int ival;
- static c_e1 data1[10]={E1_RED, E1_GREEN, E1_BLUE, E1_GREEN, E1_WHITE,
+ static c_e1 data1[10] = {E1_RED, E1_GREEN, E1_BLUE, E1_GREEN, E1_WHITE,
E1_WHITE, E1_BLACK, E1_GREEN, E1_BLUE, E1_RED};
c_e1 data2[10];
const char *envval = NULL;
TESTING("O(1) conversions");
+
envval = HDgetenv("HDF5_DRIVER");
- if (envval == NULL)
+ if(envval == NULL)
envval = "nomatch";
- if (HDstrcmp(envval, "split")) {
- if ((cwg=H5Gcreate(file, "test_tr1", 0))<0) goto error;
-
- if ((m_type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(m_type, "RED", CPTR(eval, E1_RED ))<0) goto error;
- if (H5Tenum_insert(m_type, "GREEN", CPTR(eval, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(m_type, "BLUE", CPTR(eval, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(m_type, "WHITE", CPTR(eval, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(m_type, "BLACK", CPTR(eval, E1_BLACK))<0) goto error;
-
-
- if ((f_type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(f_type, "RED", CPTR(ival, 105))<0) goto error;
- if (H5Tenum_insert(f_type, "GREEN", CPTR(ival, 104))<0) goto error;
- if (H5Tenum_insert(f_type, "BLUE", CPTR(ival, 103))<0) goto error;
- if (H5Tenum_insert(f_type, "WHITE", CPTR(ival, 102))<0) goto error;
- if (H5Tenum_insert(f_type, "BLACK", CPTR(ival, 101))<0) goto error;
-
- if ((space=H5Screate_simple(1, ds_size, NULL))<0) goto error;
- if ((dset=H5Dcreate(cwg, "color_table", f_type, space, H5P_DEFAULT))<0)
- goto error;
- if (H5Dwrite(dset, m_type, space, space, H5P_DEFAULT, data1)<0) goto error;
- if (H5Dread(dset, m_type, space, space, H5P_DEFAULT, data2)<0) goto error;
-
- for (i=0; i<(size_t)ds_size[0]; i++) {
- if (data1[i]!=data2[i]) {
+ if(HDstrcmp(envval, "split")) {
+ if((cwg = H5Gcreate2(file, "test_tr1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+
+ if((m_type = H5Tcreate(H5T_ENUM, sizeof(c_e1))) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "RED", CPTR(eval, E1_RED )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "GREEN", CPTR(eval, E1_GREEN)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "BLUE", CPTR(eval, E1_BLUE )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "WHITE", CPTR(eval, E1_WHITE)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "BLACK", CPTR(eval, E1_BLACK)) < 0) FAIL_STACK_ERROR
+
+
+ if((f_type = H5Tcreate(H5T_ENUM, sizeof(c_e1))) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "RED", CPTR(ival, 105)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "GREEN", CPTR(ival, 104)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "BLUE", CPTR(ival, 103)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "WHITE", CPTR(ival, 102)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "BLACK", CPTR(ival, 101)) < 0) FAIL_STACK_ERROR
+
+ if((space = H5Screate_simple(1, ds_size, NULL)) < 0) FAIL_STACK_ERROR
+ if((dset = H5Dcreate(cwg, "color_table", f_type, space, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Dwrite(dset, m_type, space, space, H5P_DEFAULT, data1) < 0) FAIL_STACK_ERROR
+ if(H5Dread(dset, m_type, space, space, H5P_DEFAULT, data2) < 0) FAIL_STACK_ERROR
+
+ for(i = 0; i < (size_t)ds_size[0]; i++)
+ if(data1[i] != data2[i]) {
H5_FAILED();
printf(" data1[%lu]=%d, data2[%lu]=%d (should be same)\n",
(unsigned long)i, (int)(data1[i]),
(unsigned long)i, (int)(data2[i]));
goto error;
}
- }
- if (H5Dclose(dset)<0) goto error;
- if (H5Sclose(space)<0) goto error;
- if (H5Tclose(m_type)<0) goto error;
- if (H5Tclose(f_type)<0) goto error;
- if (H5Gclose(cwg)<0) goto error;
+ if(H5Dclose(dset) < 0) FAIL_STACK_ERROR
+ if(H5Sclose(space) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(m_type) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(f_type) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(cwg) < 0) FAIL_STACK_ERROR
+
PASSED();
}
else
{
SKIPPED();
+ puts(" Test not compatible with current Virtual File Driver");
}
return 0;
- error:
- H5E_BEGIN_TRY {
- H5Dclose(dset);
- H5Sclose(space);
- H5Tclose(m_type);
- H5Tclose(f_type);
- H5Gclose(cwg);
- } H5E_END_TRY;
- return 1;
+error:
+ H5E_BEGIN_TRY {
+ H5Dclose(dset);
+ H5Sclose(space);
+ H5Tclose(m_type);
+ H5Tclose(f_type);
+ H5Gclose(cwg);
+ } H5E_END_TRY;
+ return 1;
}
@@ -294,58 +296,58 @@ test_tr1(hid_t file)
static int
test_tr2(hid_t file)
{
- hid_t cwg=-1, m_type=-1, f_type=-1, space=-1, dset=-1;
- hsize_t ds_size[1]={10};
+ hid_t cwg = -1, m_type = -1, f_type = -1, space = -1, dset = -1;
+ hsize_t ds_size[1] = {10};
size_t i;
c_e1 val1;
int val2;
- static c_e1 data1[10]={E1_RED, E1_GREEN, E1_BLUE, E1_GREEN, E1_WHITE,
+ static c_e1 data1[10] = {E1_RED, E1_GREEN, E1_BLUE, E1_GREEN, E1_WHITE,
E1_WHITE, E1_BLACK, E1_GREEN, E1_BLUE, E1_RED};
c_e1 data2[10];
const char *envval = NULL;
TESTING("O(log N) converions");
+
envval = HDgetenv("HDF5_DRIVER");
- if (envval == NULL)
+ if(envval == NULL)
envval = "nomatch";
- if (HDstrcmp(envval, "split")) {
- if ((cwg=H5Gcreate(file, "test_tr2", 0))<0) goto error;
-
- if ((m_type = H5Tcreate(H5T_ENUM, sizeof(c_e1)))<0) goto error;
- if (H5Tenum_insert(m_type, "RED", CPTR(val1, E1_RED ))<0) goto error;
- if (H5Tenum_insert(m_type, "GREEN", CPTR(val1, E1_GREEN))<0) goto error;
- if (H5Tenum_insert(m_type, "BLUE", CPTR(val1, E1_BLUE ))<0) goto error;
- if (H5Tenum_insert(m_type, "WHITE", CPTR(val1, E1_WHITE))<0) goto error;
- if (H5Tenum_insert(m_type, "BLACK", CPTR(val1, E1_BLACK))<0) goto error;
-
- if ((f_type = H5Tcreate(H5T_ENUM, sizeof(int)))<0) goto error;
- if (H5Tenum_insert(f_type, "RED", CPTR(val2, 1050))<0) goto error;
- if (H5Tenum_insert(f_type, "GREEN", CPTR(val2, 1040))<0) goto error;
- if (H5Tenum_insert(f_type, "BLUE", CPTR(val2, 1030))<0) goto error;
- if (H5Tenum_insert(f_type, "WHITE", CPTR(val2, 1020))<0) goto error;
- if (H5Tenum_insert(f_type, "BLACK", CPTR(val2, 1010))<0) goto error;
-
- if ((space=H5Screate_simple(1, ds_size, NULL))<0) goto error;
- if ((dset=H5Dcreate(cwg, "color_table", f_type, space, H5P_DEFAULT))<0)
- goto error;
- if (H5Dwrite(dset, m_type, space, space, H5P_DEFAULT, data1)<0) goto error;
- if (H5Dread(dset, m_type, space, space, H5P_DEFAULT, data2)<0) goto error;
-
- for (i=0; i<(size_t)ds_size[0]; i++) {
- if (data1[i]!=data2[i]) {
+ if(HDstrcmp(envval, "split")) {
+ if((cwg = H5Gcreate2(file, "test_tr2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+
+ if((m_type = H5Tcreate(H5T_ENUM, sizeof(c_e1))) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "RED", CPTR(val1, E1_RED )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "GREEN", CPTR(val1, E1_GREEN)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "BLUE", CPTR(val1, E1_BLUE )) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "WHITE", CPTR(val1, E1_WHITE)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(m_type, "BLACK", CPTR(val1, E1_BLACK)) < 0) FAIL_STACK_ERROR
+
+ if((f_type = H5Tcreate(H5T_ENUM, sizeof(int))) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "RED", CPTR(val2, 1050)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "GREEN", CPTR(val2, 1040)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "BLUE", CPTR(val2, 1030)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "WHITE", CPTR(val2, 1020)) < 0) FAIL_STACK_ERROR
+ if(H5Tenum_insert(f_type, "BLACK", CPTR(val2, 1010)) < 0) FAIL_STACK_ERROR
+
+ if((space = H5Screate_simple(1, ds_size, NULL)) < 0) FAIL_STACK_ERROR
+ if((dset = H5Dcreate(cwg, "color_table", f_type, space, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Dwrite(dset, m_type, space, space, H5P_DEFAULT, data1) < 0) FAIL_STACK_ERROR
+ if(H5Dread(dset, m_type, space, space, H5P_DEFAULT, data2) < 0) FAIL_STACK_ERROR
+
+ for(i = 0; i < (size_t)ds_size[0]; i++)
+ if(data1[i] != data2[i]) {
H5_FAILED();
printf(" data1[%lu]=%d, data2[%lu]=%d (should be same)\n",
(unsigned long)i, (int)(data1[i]),
(unsigned long)i, (int)(data2[i]));
goto error;
}
- }
- if (H5Dclose(dset)<0) goto error;
- if (H5Sclose(space)<0) goto error;
- if (H5Tclose(m_type)<0) goto error;
- if (H5Tclose(f_type)<0) goto error;
- if (H5Gclose(cwg)<0) goto error;
+ if(H5Dclose(dset) < 0) FAIL_STACK_ERROR
+ if(H5Sclose(space) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(m_type) < 0) FAIL_STACK_ERROR
+ if(H5Tclose(f_type) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(cwg) < 0) FAIL_STACK_ERROR
+
PASSED();
}
else
@@ -355,15 +357,15 @@ test_tr2(hid_t file)
}
return 0;
- error:
- H5E_BEGIN_TRY {
- H5Dclose(dset);
- H5Sclose(space);
- H5Tclose(m_type);
- H5Tclose(f_type);
- H5Gclose(cwg);
- } H5E_END_TRY;
- return 1;
+error:
+ H5E_BEGIN_TRY {
+ H5Dclose(dset);
+ H5Sclose(space);
+ H5Tclose(m_type);
+ H5Tclose(f_type);
+ H5Gclose(cwg);
+ } H5E_END_TRY;
+ return 1;
}
diff --git a/test/external.c b/test/external.c
index db57afb..518527b 100644
--- a/test/external.c
+++ b/test/external.c
@@ -623,31 +623,27 @@ test_2 (hid_t fapl)
* output looks like.
*/
h5_fixname(FILENAME[1], fapl, filename, sizeof filename);
- if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0) {
- goto error;
- }
- if ((grp=H5Gcreate(file, "emit-diagnostics", 8))<0) goto error;
- if (H5Gclose(grp)<0) goto error;
+ if((file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+ if((grp = H5Gcreate2(file, "emit-diagnostics", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(grp) < 0) FAIL_STACK_ERROR
/* Create the dataset */
- if((dcpl=H5Pcreate(H5P_DATASET_CREATE))<0) goto error;
- if (H5Pset_external (dcpl, "extern_1a.raw", (off_t)0, (hsize_t)sizeof part)<0 ||
- H5Pset_external (dcpl, "extern_2a.raw", (off_t)10, (hsize_t)sizeof part)<0 ||
- H5Pset_external (dcpl, "extern_3a.raw", (off_t)20, (hsize_t)sizeof part)<0 ||
- H5Pset_external (dcpl, "extern_4a.raw", (off_t)30, (hsize_t)sizeof part)<0)
+ if((dcpl = H5Pcreate(H5P_DATASET_CREATE))<0) goto error;
+ if(H5Pset_external(dcpl, "extern_1a.raw", (off_t)0, (hsize_t)sizeof part) < 0 ||
+ H5Pset_external(dcpl, "extern_2a.raw", (off_t)10, (hsize_t)sizeof part) < 0 ||
+ H5Pset_external(dcpl, "extern_3a.raw", (off_t)20, (hsize_t)sizeof part) < 0 ||
+ H5Pset_external(dcpl, "extern_4a.raw", (off_t)30, (hsize_t)sizeof part) < 0)
goto error;
cur_size = 100;
- if ((space=H5Screate_simple (1, &cur_size, NULL))<0) goto error;
- if ((dset=H5Dcreate(file, "dset1", H5T_NATIVE_INT, space, dcpl))<0)
- goto error;
+ if((space = H5Screate_simple(1, &cur_size, NULL)) < 0) goto error;
+ if((dset = H5Dcreate(file, "dset1", H5T_NATIVE_INT, space, dcpl)) < 0) goto error;
/*
* Read the entire dataset and compare with the original
*/
- memset (whole, 0, sizeof(whole));
- if (H5Dread(dset, H5T_NATIVE_INT, space, space, H5P_DEFAULT, whole)<0)
- goto error;
- for (i=0; i<100; i++) {
+ memset(whole, 0, sizeof(whole));
+ if(H5Dread(dset, H5T_NATIVE_INT, space, space, H5P_DEFAULT, whole) < 0) goto error;
+ for(i = 0; i < 100; i++) {
if (whole[i]!=(signed)i) {
H5_FAILED();
puts(" Incorrect value(s) read.");
@@ -842,11 +838,9 @@ main (void)
h5_reset();
fapl = h5_fileaccess();
h5_fixname(FILENAME[0], fapl, filename, sizeof filename);
- if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0) {
- goto error;
- }
- if ((grp=H5Gcreate(file, "emit-diagnostics", 8))<0) goto error;
- if (H5Gclose (grp)<0) goto error;
+ if((file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+ if((grp = H5Gcreate2(file, "emit-diagnostics", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(grp) < 0) goto error;
nerrors += test_1a(file);
nerrors += test_1b(file);
diff --git a/test/flush1.c b/test/flush1.c
index 5f8eefc..04345e0 100644
--- a/test/flush1.c
+++ b/test/flush1.c
@@ -58,42 +58,37 @@ create_file(char* name, hid_t fapl)
hsize_t ch_size[2] = {5, 5};
size_t i, j;
- if ((file=H5Fcreate(name, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0) goto error;
+ if((file = H5Fcreate(name, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
/* Create a chunked dataset */
- if ((dcpl=H5Pcreate(H5P_DATASET_CREATE))<0) goto error;
- if (H5Pset_chunk(dcpl, 2, ch_size)<0) goto error;
- if ((space=H5Screate_simple(2, ds_size, NULL))<0) goto error;
- if ((dset=H5Dcreate(file, "dset", H5T_NATIVE_FLOAT, space, H5P_DEFAULT))<0)
- goto error;
+ if((dcpl = H5Pcreate(H5P_DATASET_CREATE)) < 0) FAIL_STACK_ERROR
+ if(H5Pset_chunk(dcpl, 2, ch_size) < 0) FAIL_STACK_ERROR
+ if((space = H5Screate_simple(2, ds_size, NULL)) < 0) FAIL_STACK_ERROR
+ if((dset = H5Dcreate(file, "dset", H5T_NATIVE_FLOAT, space, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Write some data */
- for (i=0; i<ds_size[0]; i++) {
+ for(i = 0; i < ds_size[0]; i++)
/*
* The extra cast in the following statement is a bug workaround
* for the Win32 version 5.0 compiler.
* 1998-11-06 ptl
*/
- for (j=0; j<(size_t)ds_size[1]; j++) {
+ for(j = 0; j < (size_t)ds_size[1]; j++)
the_data[i][j] = (double)(hssize_t)i/(hssize_t)(j+1);
- }
- }
- if (H5Dwrite(dset, H5T_NATIVE_DOUBLE, space, space, H5P_DEFAULT,
- the_data)<0) goto error;
+ if(H5Dwrite(dset, H5T_NATIVE_DOUBLE, space, space, H5P_DEFAULT, the_data) < 0) FAIL_STACK_ERROR
/* Create some groups */
- if ((groups=H5Gcreate(file, "some_groups", 0))<0) goto error;
- for (i=0; i<100; i++) {
+ if((groups = H5Gcreate2(file, "some_groups", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ for(i = 0; i < 100; i++) {
sprintf(name, "grp%02u", (unsigned)i);
- if ((grp=H5Gcreate(groups, name, 0))<0) goto error;
- if (H5Gclose(grp)<0) goto error;
- }
+ if((grp = H5Gcreate2(groups, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(grp)<0) FAIL_STACK_ERROR
+ } /* end for */
return file;
error:
- HD_exit(1);
-
+ HD_exit(1);
}
diff --git a/test/gen_mergemsg.c b/test/gen_mergemsg.c
index 8777197..f070901 100644
--- a/test/gen_mergemsg.c
+++ b/test/gen_mergemsg.c
@@ -52,7 +52,7 @@ int main()
assert(fid > 0);
/* Create first group */
- gid = H5Gcreate(fid, GROUP1, (size_t)0);
+ gid = H5Gcreate2(fid, GROUP1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
assert(gid > 0);
/* Close first group */
@@ -60,7 +60,7 @@ int main()
assert(ret >= 0);
/* Create second group */
- gid2 = H5Gcreate(fid, GROUP2, (size_t)0);
+ gid2 = H5Gcreate2(fid, GROUP2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
assert(gid2 > 0);
/* Close second group */
@@ -146,7 +146,7 @@ int main()
assert(fid > 0);
/* Create third group */
- gid3 = H5Gcreate(fid, GROUP3, (size_t)0);
+ gid3 = H5Gcreate2(fid, GROUP3, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
assert(gid3 > 0);
/* Close third group */
diff --git a/test/gen_new_group.c b/test/gen_new_group.c
index 5a3dbfe..18a5416 100644
--- a/test/gen_new_group.c
+++ b/test/gen_new_group.c
@@ -73,11 +73,11 @@ int main(void)
if((sid = H5Screate(H5S_SCALAR)) < 0) goto error;
/* Create empty group (w/default group creation properties) */
- if((gid = H5Gcreate(fid, "empty", (size_t)0)) < 0) goto error;
+ if((gid = H5Gcreate2(fid, "empty", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
if(H5Gclose(gid) < 0) goto error;
/* Create group which will contain link messages (w/default group creation properties) */
- if((gid = H5Gcreate(fid, "links", (size_t)0)) < 0) goto error;
+ if((gid = H5Gcreate2(fid, "links", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
/* Create dataset in group */
if((did = H5Dcreate(gid, "dset1", H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0) goto error;
diff --git a/test/gen_old_group.c b/test/gen_old_group.c
index 46f60ee..1b33cea 100644
--- a/test/gen_old_group.c
+++ b/test/gen_old_group.c
@@ -42,7 +42,7 @@ int main(void)
if((fid = H5Fcreate(FILENAME, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) <0) goto error;
/* Create empty group that uses "symbol table" form to store links */
- if((gid = H5Gcreate(fid, "old", (size_t)0)) < 0) goto error;
+ if((gid = H5Gcreate2(fid, "old", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
if(H5Gclose(gid) < 0) goto error;
/* Close file */
diff --git a/test/gen_udlinks.c b/test/gen_udlinks.c
index 5e52ace..b7e35ef 100644
--- a/test/gen_udlinks.c
+++ b/test/gen_udlinks.c
@@ -62,9 +62,9 @@ main (void)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
/* Create two groups in the second file */
- if((gid = H5Gcreate(fid2, "group", (size_t)0)) < 0) goto error;
+ if((gid = H5Gcreate2(fid2, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
if((H5Gclose(gid)) < 0) goto error;
- if((gid = H5Gcreate(fid2, "group/subgroup", (size_t)0)) < 0) goto error;
+ if((gid = H5Gcreate2(fid2, "group/subgroup", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
if((H5Gclose(gid)) < 0) goto error;
/* Create an external link in the first file pointing to the group in the second file */
diff --git a/test/getname.c b/test/getname.c
index 5fa673b..9700df3 100644
--- a/test/getname.c
+++ b/test/getname.c
@@ -108,14 +108,14 @@ test_main(hid_t file_id, hid_t fapl)
h5_fixname(FILENAME[3], fapl, filename3, sizeof filename3);
/*-------------------------------------------------------------------------
- * Test H5Iget_name with H5Gcreate, one group
+ * Test H5Iget_name with one group
*-------------------------------------------------------------------------
*/
- TESTING("H5Iget_name with H5Gcreate, one group");
+ TESTING("H5Iget_name with one group");
/* Create group "g0" in the root group using absolute name */
- if ((group_id = H5Gcreate( file_id, "/g0", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g0", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Verify */
if(check_name(group_id, "/g0", "/g0") < 0) TEST_ERROR;
@@ -128,16 +128,16 @@ test_main(hid_t file_id, hid_t fapl)
/*-------------------------------------------------------------------------
- * Test H5Iget_name with H5Gcreate, more than one group
+ * Test H5Iget_name with more than one group
*-------------------------------------------------------------------------
*/
- TESTING("H5Iget_name with H5Gcreate, more than one group");
+ TESTING("H5Iget_name with more than one group");
/* Create group "g1" in the root group using absolute name */
- if ((group_id = H5Gcreate( file_id, "/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create group "g2" in group "g1" using absolute name */
- if ((group2_id = H5Gcreate( file_id, "/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group2_id = H5Gcreate2(file_id, "/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Verify */
if(check_name(group_id, "/g1", "/g1") < 0) TEST_ERROR;
@@ -259,14 +259,13 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with a long path");
/* Create group "g2/bar/baz" */
- if ((group_id = H5Gcreate( file_id, "g2", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "g2/bar", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "g2/bar/baz", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "g2/bar", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "g2/bar/baz", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create a dataset */
- if ((space_id = H5Screate_simple( 1, dims, NULL ))<0) TEST_ERROR;
- if ((dataset_id = H5Dcreate( group3_id , "d1", H5T_NATIVE_INT, space_id,
- H5P_DEFAULT ))<0) TEST_ERROR;
+ if((space_id = H5Screate_simple( 1, dims, NULL ))<0) TEST_ERROR;
+ if((dataset_id = H5Dcreate(group3_id , "d1", H5T_NATIVE_INT, space_id, H5P_DEFAULT ))<0) TEST_ERROR;
/* Close */
H5Dclose( dataset_id );
@@ -410,10 +409,10 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Gmove and relative names");
/* Create group "/g3" */
- if ((group_id = H5Gcreate( file_id, "/g3", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create group "/g3/foo" using absolute name */
- if ((group2_id = H5Gcreate( file_id, "/g3/foo1", 0 ))<0) TEST_ERROR;
+ if((group2_id = H5Gcreate2(file_id, "/g3/foo1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Open group "/g3/foo" again */
if ((group3_id = H5Gopen( file_id, "/g3/foo1"))<0) TEST_ERROR;
@@ -460,13 +459,13 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Gmove and a long path");
/* Create group "g4/A/B" */
- if ((group_id = H5Gcreate( file_id, "g4", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "g4/A", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "g4/A/B", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "g4/A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "g4/A/B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create group "g5/C" */
- if ((group4_id = H5Gcreate( file_id, "g5", 0 ))<0) TEST_ERROR;
- if ((group5_id = H5Gcreate( file_id, "g5/C", 0 ))<0) TEST_ERROR;
+ if((group4_id = H5Gcreate2(file_id, "g5", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group5_id = H5Gcreate2(file_id, "g5/C", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Verify */
if(check_name(group3_id, "/g4/A/B", "/g4/A/B") < 0) TEST_ERROR;
@@ -510,10 +509,10 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Gmove and a long path #2");
/* Create group "g6/A/B" and "g7" */
- if ((group_id = H5Gcreate( file_id, "g6", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "g6/A", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "g6/A/B", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file_id, "g7", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g6", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "g6/A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "g6/A/B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file_id, "g7", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Verify */
if(check_name(group3_id, "/g6/A/B", "/g6/A/B") < 0) TEST_ERROR;
@@ -543,7 +542,7 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Gunlink");
/* Create a new group. */
- if ((group_id = H5Gcreate( file_id, "/g8", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g8", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Delete */
if (H5Gunlink( file_id, "/g8")<0) TEST_ERROR;
@@ -564,9 +563,9 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Gunlink and a long path");
/* Create group "g9/a/b" */
- if ((group_id = H5Gcreate( file_id, "g9", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "g9/a", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "g9/a/b", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g9", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "g9/a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "g9/a/b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Delete */
if (H5Gunlink( file_id, "/g9/a")<0) TEST_ERROR;
@@ -582,8 +581,8 @@ test_main(hid_t file_id, hid_t fapl)
H5Gclose( group3_id );
/* Recreate groups */
- if ((group2_id = H5Gcreate( group_id, "a", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( group_id, "a/b", 0 ))<0) TEST_ERROR;
+ if((group2_id = H5Gcreate2(group_id, "a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(group_id, "a/b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Delete, using relative path */
if (H5Gunlink( group_id, "a")<0) TEST_ERROR;
@@ -602,9 +601,9 @@ test_main(hid_t file_id, hid_t fapl)
H5Gclose( group_id );
/* Create group "g10/a/b" */
- if ((group_id = H5Gcreate( file_id, "g10", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "g10/a", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "g10/a/b", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g10", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "g10/a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "g10/a/b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Delete */
if (H5Gunlink( file_id, "/g10/a/b")<0) TEST_ERROR;
@@ -616,7 +615,7 @@ test_main(hid_t file_id, hid_t fapl)
H5Gclose( group3_id );
/* Recreate group */
- if ((group3_id = H5Gcreate( group_id, "a/b", 0 ))<0) TEST_ERROR;
+ if((group3_id = H5Gcreate2(group_id, "a/b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Delete, using relative path */
if (H5Gunlink( group_id, "a/b")<0) TEST_ERROR;
@@ -642,8 +641,8 @@ test_main(hid_t file_id, hid_t fapl)
/* Create group "g11/g" */
- if ((group_id = H5Gcreate( file_id, "g11", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "g11/g", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g11", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "g11/g", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create two datasets "g11/d" and "g11/g/d"*/
if ((space_id = H5Screate_simple( 1, dims, NULL ))<0) TEST_ERROR;
@@ -677,7 +676,7 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Fmount; with IDs on the list");
/* Create a group "g12" in the first file */
- if ((group_id = H5Gcreate( file_id, "/g12", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g12", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -722,9 +721,9 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Fmount; long name");
/* Create a group "g13/g1/g2" in the first file */
- if ((group_id = H5Gcreate( file_id, "/g13", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g13/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g13/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g13", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g13/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g13/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -734,9 +733,9 @@ test_main(hid_t file_id, hid_t fapl)
/* Create second file and group "g" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g14", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g14/g3", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g14/g3/g4", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g14", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g14/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g14/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -911,10 +910,10 @@ test_main(hid_t file_id, hid_t fapl)
TESTING("H5Iget_name with H5Funmount");
/* Create a group "g15/g1/g2" in the first file */
- if ((group_id = H5Gcreate( file_id, "/g15", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g15/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g15/g1/g2", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file_id, "/g15/g1/g2/g3", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g15", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g15/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g15/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file_id, "/g15/g1/g2/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -925,9 +924,9 @@ test_main(hid_t file_id, hid_t fapl)
/* Create second file and group "g" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g16", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g16/g4", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g16/g4/g5", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g16", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g16/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g16/g4/g5", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -982,7 +981,7 @@ test_main(hid_t file_id, hid_t fapl)
if (H5Tinsert (type_id, "c", HOFFSET(s1_t,c), H5T_NATIVE_FLOAT)<0) TEST_ERROR;
/* Create group "g17" */
- if ((group_id = H5Gcreate( file_id, "g17", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "g17", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Save datatype for later */
if (H5Tcommit (group_id, "t", type_id)<0) TEST_ERROR;
@@ -1250,8 +1249,8 @@ PASSED();
TESTING("H5Iget_name with added names with mounting");
/* Create a group "g18/g2" in the first file */
- if ((group_id = H5Gcreate( file_id, "/g18", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g18/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g18", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g18/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Also create a dataset and a datatype */
if ((space_id = H5Screate_simple( 1, dims, NULL ))<0) TEST_ERROR;
@@ -1263,9 +1262,9 @@ PASSED();
/* Create second file and group "/g3/g4/g5" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group3_id = H5Gcreate( file1_id, "/g3", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file1_id, "/g3/g4", 0 ))<0) TEST_ERROR;
- if ((group5_id = H5Gcreate( file1_id, "/g3/g4/g5", 0 ))<0) TEST_ERROR;
+ if((group3_id = H5Gcreate2(file1_id, "/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file1_id, "/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group5_id = H5Gcreate2(file1_id, "/g3/g4/g5", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Mount first file at "g3/g4" in the second file */
if (H5Fmount(file1_id, "/g3/g4", file_id, H5P_DEFAULT)<0) TEST_ERROR;
@@ -1319,7 +1318,7 @@ PASSED();
H5Gclose( group6_id );
H5Fclose( file1_id );
-PASSED();
+ PASSED();
/*-------------------------------------------------------------------------
@@ -1331,8 +1330,8 @@ PASSED();
/* Create a file and group "/g1/g2" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g1", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Verify */
if(check_name(group2_id, "/g1/g2", "/g1/g2") < 0) TEST_ERROR;
@@ -1359,13 +1358,13 @@ PASSED();
/* Create a file and group "/g1/g2" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g1", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create a new file and group "/g3/g4" in it */
- if ((file2_id = H5Fcreate( filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file2_id, "/g3", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file2_id, "/g3/g4", 0 ))<0) TEST_ERROR;
+ if((file2_id = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl )) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file2_id, "/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file2_id, "/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Mount first file at "/g3/g4" in the second file */
if(H5Fmount(file2_id, "/g3/g4", file1_id, H5P_DEFAULT)<0) TEST_ERROR;
@@ -1407,13 +1406,13 @@ PASSED();
/* Create a file and group "/g1/g2" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g1", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create a new file and group "/g3/g4" in it */
- if ((file2_id = H5Fcreate( filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file2_id, "/g3", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file2_id, "/g3/g4", 0 ))<0) TEST_ERROR;
+ if((file2_id = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl )) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file2_id, "/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file2_id, "/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Mount first file at "g3/g4" in the second file */
if(H5Fmount(file2_id, "/g3/g4", file1_id, H5P_DEFAULT)<0) TEST_ERROR;
@@ -1505,8 +1504,8 @@ PASSED();
TESTING("H5Iget_name with H5Glink hard");
/* Create group "g19/g1" */
- if ((group_id = H5Gcreate( file_id, "/g19", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g19/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g19", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g19/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create hard link to "g19/g1/ group */
if (H5Glink(file_id, H5G_LINK_HARD, "/g19/g1", "/g19/g2")<0) TEST_ERROR;
@@ -1591,8 +1590,8 @@ PASSED();
TESTING("H5Iget_name with H5Glink symbolic");
/* Create group "g20/g1" */
- if ((group_id = H5Gcreate( file_id, "/g20", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g20/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g20", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g20/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create symbolic link to "g20/g1/ group */
if (H5Glink(file_id, H5G_LINK_SOFT, "/g20/g1", "/g20/g2")<0) TEST_ERROR;
@@ -1622,8 +1621,8 @@ PASSED();
TESTING("H5Iget_name with H5Glink symbolic and move target");
/* Create group "g21/g1" */
- if ((group_id = H5Gcreate( file_id, "/g21", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g21/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g21", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g21/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create symbolic link to "g21/g1/ group */
if (H5Glink(file_id, H5G_LINK_SOFT, "/g21/g1", "/g21/g2")<0) TEST_ERROR;
@@ -1657,8 +1656,8 @@ PASSED();
TESTING("H5Iget_name with H5Glink symbolic and move source");
/* Create group "g22/g1" */
- if ((group_id = H5Gcreate( file_id, "/g22", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g22/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g22", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g22/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create symbolic link to "g22/g1/ group */
if (H5Glink(file_id, H5G_LINK_SOFT, "/g22/g1", "/g22/g2")<0) TEST_ERROR;
@@ -1700,8 +1699,8 @@ PASSED();
TESTING("H5Iget_name with H5Glink symbolic and unlink target");
/* Create group "g23/g1" */
- if ((group_id = H5Gcreate( file_id, "/g23", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g23/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g23", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g23/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create symbolic link to "g23/g1/ group */
if (H5Glink(file_id, H5G_LINK_SOFT, "/g23/g1", "/g23/g2")<0) TEST_ERROR;
@@ -1733,8 +1732,8 @@ PASSED();
TESTING("H5Iget_name with H5Glink symbolic and unlink source");
/* Create group "g24/g1" */
- if ((group_id = H5Gcreate( file_id, "/g24", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g24/g1", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g24", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g24/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create symbolic link to "g24/g1/ group */
if (H5Glink(file_id, H5G_LINK_SOFT, "/g24/g1", "/g24/g2")<0) TEST_ERROR;
@@ -1766,9 +1765,9 @@ PASSED();
TESTING("H5Iget_name with several nested mounted files");
/* Create a group "g25/g1/g2" in the first file */
- if ((group_id = H5Gcreate( file_id, "/g25", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g25/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g25/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g25", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g25/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g25/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1778,9 +1777,9 @@ PASSED();
/* Create second file and group "/g26/g3/g4" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g26", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g26/g3", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g26/g3/g4", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g26", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g26/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g26/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1790,9 +1789,9 @@ PASSED();
/* Create third file and group "/g27/g5/g6" in it */
file2_id = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file2_id, "/g27", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file2_id, "/g27/g5", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file2_id, "/g27/g5/g6", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file2_id, "/g27", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file2_id, "/g27/g5", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file2_id, "/g27/g5/g6", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1802,9 +1801,9 @@ PASSED();
/* Create fourth file and group "/g28/g5/g6" in it */
file3_id = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file3_id, "/g28", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file3_id, "/g28/g7", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file3_id, "/g28/g7/g8", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file3_id, "/g28", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file3_id, "/g28/g7", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file3_id, "/g28/g7/g8", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1899,11 +1898,11 @@ PASSED();
TESTING("H5Iget_name and H5Gmove with repeated path components");
/* Create a group "g29/g1/g2/g1/g2" in a file */
- if ((group_id = H5Gcreate( file_id, "/g29", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g29/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g29/g1/g2", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file_id, "/g29/g1/g2/g1", 0 ))<0) TEST_ERROR;
- if ((group5_id = H5Gcreate( file_id, "/g29/g1/g2/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g29", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g29/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g29/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file_id, "/g29/g1/g2/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group5_id = H5Gcreate2(file_id, "/g29/g1/g2/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Rename group */
if (H5Gmove( file_id, "/g29/g1/g2/g1/g2", "/g29/g1/g2/g1/g3" )<0) TEST_ERROR;
@@ -1943,9 +1942,9 @@ PASSED();
TESTING("H5Iget_name with higher mounted file");
/* Create a group "/g30/g1/g2" in the first file */
- if ((group_id = H5Gcreate( file_id, "/g30", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g30/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g30/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g30", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g30/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g30/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1955,9 +1954,9 @@ PASSED();
/* Create second file and group "/g31/g3/g4" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g31", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g31/g3", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g31/g3/g4", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g31", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g31/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g31/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1967,9 +1966,9 @@ PASSED();
/* Create third file and group "/g32/g5/g6" in it */
file2_id = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file2_id, "/g32", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file2_id, "/g32/g5", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file2_id, "/g32/g5/g6", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file2_id, "/g32", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file2_id, "/g32/g5", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file2_id, "/g32/g5/g6", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -1979,9 +1978,9 @@ PASSED();
/* Create fourth file and group "/g33/g5/g6" in it */
file3_id = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file3_id, "/g33", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file3_id, "/g33/g7", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file3_id, "/g33/g7/g8", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file3_id, "/g33", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file3_id, "/g33/g7", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file3_id, "/g33/g7/g8", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2081,9 +2080,9 @@ PASSED();
/* Create second file and group "/g35/g3/g4" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g35", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g35/g3", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g35/g3/g4", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g35", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g35/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g35/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2091,9 +2090,9 @@ PASSED();
H5Gclose( group3_id );
/* Create group "/g34/g1/g2" in first file */
- if ((group_id = H5Gcreate( file_id, "/g34", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g34/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g34/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g34", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g34/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g34/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create hard link to "/g34/g1/g2 group */
if (H5Glink(file_id, H5G_LINK_HARD, "/g34/g1/g2", "/g34/g2a")<0) TEST_ERROR;
@@ -2140,9 +2139,9 @@ PASSED();
TESTING("H5Iget_name with mounted files and unlinking");
/* Create group "/g36/g1/g2" in first file */
- if ((group_id = H5Gcreate( file_id, "/g36", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file_id, "/g36/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file_id, "/g36/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file_id, "/g36", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file_id, "/g36/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file_id, "/g36/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2152,10 +2151,10 @@ PASSED();
/* Create second file and group "/g37/g4" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g37", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g37/g4", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g37/g4/g5a", 0 ))<0) TEST_ERROR;
- if ((group4_id = H5Gcreate( file1_id, "/g37/g4/g5b", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g37", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g37/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g37/g4/g5a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group4_id = H5Gcreate2(file1_id, "/g37/g4/g5b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Mount second file under "/g36/g1" in the first file */
if (H5Fmount(file_id, "/g36/g1", file1_id, H5P_DEFAULT)<0) TEST_ERROR;
@@ -2229,9 +2228,9 @@ PASSED();
/* Create file and group "/g38/g1/g2" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g38", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g38/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g38/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g38", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g38/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g38/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2241,9 +2240,9 @@ PASSED();
/* Create second file and group "/g39/g1/g2" in it */
file2_id = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file2_id, "/g39", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file2_id, "/g39/g3", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file2_id, "/g39/g3/g4", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file2_id, "/g39", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file2_id, "/g39/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file2_id, "/g39/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2253,9 +2252,9 @@ PASSED();
/* Create third file and group "/g40/g5/g6" in it */
file3_id = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file3_id, "/g40", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file3_id, "/g40/g5", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file3_id, "/g40/g5/g6", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file3_id, "/g40", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file3_id, "/g40/g5", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file3_id, "/g40/g5/g6", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2311,9 +2310,9 @@ PASSED();
/* Create file and group "/g39/g1/g2" in it */
file1_id = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file1_id, "/g41", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file1_id, "/g41/g1", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file1_id, "/g41/g1/g2", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file1_id, "/g41", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file1_id, "/g41/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file1_id, "/g41/g1/g2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2323,9 +2322,9 @@ PASSED();
/* Create second file and group "/g42/g1/g2" in it */
file2_id = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
- if ((group_id = H5Gcreate( file2_id, "/g42", 0 ))<0) TEST_ERROR;
- if ((group2_id = H5Gcreate( file2_id, "/g42/g3", 0 ))<0) TEST_ERROR;
- if ((group3_id = H5Gcreate( file2_id, "/g42/g3/g4", 0 ))<0) TEST_ERROR;
+ if((group_id = H5Gcreate2(file2_id, "/g42", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group2_id = H5Gcreate2(file2_id, "/g42/g3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if((group3_id = H5Gcreate2(file2_id, "/g42/g3/g4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Close */
H5Gclose( group_id );
@@ -2393,8 +2392,7 @@ test_obj_ref(hid_t fapl)
TEST_ERROR
/* Create a group */
- if((group = H5Gcreate(fid1, "Group1", (size_t)0)) < 0)
- TEST_ERROR
+ if((group = H5Gcreate2(fid1, "Group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create a single dataset inside the second file, which will be mounted
* and used to mask objects in the first file */
@@ -2448,8 +2446,7 @@ test_obj_ref(hid_t fapl)
TEST_ERROR
/* Create a new group in group1 */
- if((group2 = H5Gcreate(group, "Group2", (size_t)0)) < 0)
- TEST_ERROR
+ if((group2 = H5Gcreate2(group, "Group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create a hard link to group1 in group2 */
if(H5Glink(fid1, H5G_LINK_HARD, "/Group1", "/Group1/Group2/Link") < 0)
diff --git a/test/h5test.c b/test/h5test.c
index 2eb87c1..db56860 100644
--- a/test/h5test.c
+++ b/test/h5test.c
@@ -90,7 +90,7 @@ MPI_Info h5_io_info_g=MPI_INFO_NULL;/* MPI INFO object for IO */
*/
static const char *multi_letters = "msbrglo";
-static herr_t h5_errors(void *client_data);
+static herr_t h5_errors(hid_t estack, void *client_data);
/*-------------------------------------------------------------------------
@@ -110,10 +110,10 @@ static herr_t h5_errors(void *client_data);
*-------------------------------------------------------------------------
*/
static herr_t
-h5_errors(void UNUSED *client_data)
+h5_errors(hid_t estack, void UNUSED *client_data)
{
H5_FAILED();
- H5Eprint2(H5E_DEFAULT, stdout);
+ H5Eprint2(estack, stdout);
return 0;
}
@@ -225,7 +225,7 @@ h5_reset(void)
H5E_BEGIN_TRY {
hid_t file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT,
H5P_DEFAULT);
- hid_t grp = H5Gcreate(file, "emit", (size_t)0);
+ hid_t grp = H5Gcreate2(file, "emit", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
H5Gclose(grp);
H5Fclose(file);
HDunlink(filename);
diff --git a/test/links.c b/test/links.c
index 67301dc..45baae6 100644
--- a/test/links.c
+++ b/test/links.c
@@ -130,8 +130,8 @@ mklinks(hid_t fapl, hbool_t new_format)
if ((scalar=H5Screate_simple (1, size, size)) < 0) TEST_ERROR
/* Create a group */
- if ((grp=H5Gcreate (file, "grp1", (size_t)0)) < 0) TEST_ERROR
- if (H5Gclose (grp) < 0) TEST_ERROR
+ if((grp = H5Gcreate2(file, "grp1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if(H5Gclose (grp) < 0) TEST_ERROR
/* Create a dataset */
if ((d1=H5Dcreate (file, "d1", H5T_NATIVE_INT, scalar, H5P_DEFAULT)) < 0) TEST_ERROR
@@ -202,10 +202,10 @@ new_links(hid_t fapl, hbool_t new_format)
if ((scalar=H5Screate_simple (1, size, size)) < 0) TEST_ERROR
/* Create two groups in each file */
- if ((grp1_a=H5Gcreate (file_a, "grp1", (size_t)0)) < 0) TEST_ERROR
- if ((grp2_a=H5Gcreate (file_a, "grp2", (size_t)0)) < 0) TEST_ERROR
- if ((grp1_b=H5Gcreate (file_b, "grp1", (size_t)0)) < 0) TEST_ERROR
- if ((grp2_b=H5Gcreate (file_b, "grp2", (size_t)0)) < 0) TEST_ERROR
+ if((grp1_a = H5Gcreate2(file_a, "grp1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp2_a = H5Gcreate2(file_a, "grp2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp1_b = H5Gcreate2(file_b, "grp1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp2_b = H5Gcreate2(file_b, "grp2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create datasets */
if((dset1=H5Dcreate(file_a, "dataset1", H5T_NATIVE_INT, scalar, H5P_DEFAULT)) < 0) TEST_ERROR
@@ -498,7 +498,7 @@ long_links(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group with short name in file (used as target for hard links) */
- if((gid=H5Gcreate (fid, "grp1", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "grp1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Construct very long file name */
if((objname = HDmalloc((size_t)(MAX_NAME_LEN + 1))) == NULL) TEST_ERROR
@@ -514,7 +514,7 @@ long_links(hid_t fapl, hbool_t new_format)
if(H5Lcreate_soft("grp1", fid, objname, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
/* Create group with long name in existing group */
- if((gid2=H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close objects */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -579,7 +579,7 @@ toomany(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group with short name in file (used as target for hard links) */
- if((gid=H5Gcreate (fid, "final", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "final", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create chain of hard links to existing object (no limit on #) */
if(H5Lcreate_hard(fid, "final", fid, "hard1", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -638,7 +638,7 @@ toomany(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/hard21")) TEST_ERROR
/* Create object in hard-linked group */
- if((gid2 = H5Gcreate(gid, "new_hard", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_hard", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in hard-linked group */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -664,7 +664,7 @@ toomany(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/soft16")) TEST_ERROR
/* Create object using soft links */
- if((gid2 = H5Gcreate(gid, "new_soft", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_soft", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close groups */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -1011,9 +1011,9 @@ test_move(hid_t fapl, hbool_t new_format)
TEST_ERROR
/* Create groups in first file */
- if((grp_1=H5Gcreate(file_a, "group1", (size_t)0)) < 0) TEST_ERROR
- if((grp_2=H5Gcreate(file_a, "group2", (size_t)0)) < 0) TEST_ERROR
- if((grp_move=H5Gcreate(grp_1, "group_move", (size_t)0)) < 0) TEST_ERROR
+ if((grp_1 = H5Gcreate2(file_a, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp_2 = H5Gcreate2(file_a, "group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp_move = H5Gcreate2(grp_1, "group_move", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create hard and soft links. */
if(H5Lcreate_hard(grp_1, "group_move", H5L_SAME_LOC, "hard", H5P_DEFAULT, H5P_DEFAULT) < 0)
@@ -1153,9 +1153,9 @@ test_copy(hid_t fapl, hbool_t new_format)
TEST_ERROR
/* Create groups in first file */
- if((grp_1=H5Gcreate(file_a, "group1", (size_t)0)) < 0) TEST_ERROR
- if((grp_2=H5Gcreate(file_a, "group2", (size_t)0)) < 0) TEST_ERROR
- if((grp_move=H5Gcreate(grp_1, "group_copy", (size_t)0)) < 0) TEST_ERROR
+ if((grp_1 = H5Gcreate2(file_a, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp_2 = H5Gcreate2(file_a, "group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp_move = H5Gcreate2(grp_1, "group_copy", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create hard and soft links. */
if(H5Lcreate_hard(grp_1, "group_copy", H5L_SAME_LOC, "hard", H5P_DEFAULT, H5P_DEFAULT) < 0)
@@ -1484,8 +1484,8 @@ test_compat(hid_t fapl, hbool_t new_format)
if((file_id = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create two groups in the file */
- if((group1_id = H5Gcreate(file_id, "group1", (size_t)1)) < 0) TEST_ERROR
- if((group2_id = H5Gcreate(file_id, "group2", (size_t)1)) < 0) TEST_ERROR
+ if((group1_id = H5Gcreate2(file_id, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((group2_id = H5Gcreate2(file_id, "group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create links using H5Glink and H5Glink2 */
if(H5Glink(file_id, H5G_LINK_HARD, "group2", "group1/link_to_group2") < 0) TEST_ERROR
@@ -1646,7 +1646,7 @@ external_link_root(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -1654,10 +1654,10 @@ external_link_root(hid_t fapl, hbool_t new_format)
/* Close external object (lets first file close) */
if(H5Gclose(gid) < 0) TEST_ERROR
- /* Create a new object using H5Gcreate through the external link
+ /* Create a new object using H5Gcreate2 through the external link
* directly
*/
- if((gid = H5Gcreate(fid, "ext_link/newer_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "ext_link/newer_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close file and group */
if(H5Gclose(gid) < 0) TEST_ERROR
@@ -1689,7 +1689,7 @@ external_link_root(hid_t fapl, hbool_t new_format)
if((fid = H5Fopen(filename2, H5F_ACC_RDONLY, H5P_DEFAULT)) < 0) TEST_ERROR
H5E_BEGIN_TRY {
- gid = H5Gcreate(fid, "ext_link/readonly_group", (size_t)0);
+ gid = H5Gcreate2(fid, "ext_link/readonly_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY
if(gid >= 0) TEST_ERROR
@@ -1749,13 +1749,13 @@ external_link_path(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object down a path */
- if((gid = H5Gcreate(fid, "A", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "A/B", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "A/B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "A/B/C", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "A/B/C", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -1776,7 +1776,7 @@ external_link_path(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/A/B/C")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -1862,13 +1862,13 @@ external_link_mult(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object down a path */
- if((gid = H5Gcreate(fid, "A", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "A/B", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "A/B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "A/B/C", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "A/B/C", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -1878,10 +1878,10 @@ external_link_mult(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create external link down a path */
- if((gid = H5Gcreate(fid, "D", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "D", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "D/E", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "D/E", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create external link to object in first file */
if(H5Lcreate_external(filename1, "/A/B/C", gid, "F", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -1895,10 +1895,10 @@ external_link_mult(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create external link down a path */
- if((gid = H5Gcreate(fid, "G", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "G", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "G/H", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "G/H", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create external link to object in second file */
if(H5Lcreate_external(filename2, "/D/E/F", gid, "I", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -1923,7 +1923,7 @@ external_link_mult(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/A/B/C")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -2047,7 +2047,7 @@ external_link_self(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/X")) TEST_ERROR
/* Create object through external link */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close created group */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -2083,7 +2083,7 @@ external_link_self(hid_t fapl, hbool_t new_format)
/* Create file3 as a target */
if((fid=H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
- if((gid=H5Gcreate(fid, "end", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "end", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
if(H5Fclose(fid) < 0) TEST_ERROR
@@ -2102,7 +2102,7 @@ external_link_self(hid_t fapl, hbool_t new_format)
if((gid=H5Gopen(fid, "ext_link/B/C/Y/Z/end")) < 0) TEST_ERROR
/* Create object through external link */
- if((gid2 = H5Gcreate(gid, "newer_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "newer_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Cleanup */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -2184,7 +2184,7 @@ external_link_pingpong(hid_t fapl, hbool_t new_format)
if(H5Lcreate_external(filename2, "/link6", fid, "link5", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
/* Create final object */
- if((gid = H5Gcreate(fid, "final", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "final", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -2213,7 +2213,7 @@ external_link_pingpong(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/final")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -2348,7 +2348,7 @@ external_link_toomany(hid_t fapl, hbool_t new_format)
if(H5Lcreate_external(filename1, "/link17", fid, "link16", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
/* Create final object */
- if((gid = H5Gcreate(fid, "final", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "final", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -2376,7 +2376,7 @@ external_link_toomany(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/final")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -2620,7 +2620,7 @@ external_link_query(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object to link to */
- if((gid = H5Gcreate(fid, "dst", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "dst", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -2732,7 +2732,7 @@ external_link_unlink_compact(hid_t fapl, hbool_t new_format)
if((fid = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object to link to */
- if((gid = H5Gcreate(fid, "dst", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "dst", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -2837,7 +2837,7 @@ external_link_unlink_dense(hid_t fapl, hbool_t new_format)
/* Create enough objects in the root group to change it into a "dense" group */
for(u = 0; u < max_compact; u++) {
sprintf(objname, "filler %u", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
} /* end for */
@@ -2859,7 +2859,7 @@ external_link_unlink_dense(hid_t fapl, hbool_t new_format)
if((fid = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object to link to */
- if((gid = H5Gcreate(fid, "dst", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "dst", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -2966,7 +2966,7 @@ external_link_move(hid_t fapl, hbool_t new_format)
if((fid = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object to link to */
- if((gid = H5Gcreate(fid, "dst", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "dst", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -2989,7 +2989,7 @@ external_link_move(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/dst")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -3018,7 +3018,7 @@ external_link_move(hid_t fapl, hbool_t new_format)
if((fid = H5Fopen(filename1, H5F_ACC_RDWR, fapl)) < 0) TEST_ERROR
/* Create another group, to move the external link into */
- if((gid = H5Gcreate(fid, "group2", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Move external link to different group */
if(H5Gmove2(fid, "src2", gid, "src3") < 0) TEST_ERROR
@@ -3034,7 +3034,7 @@ external_link_move(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/dst")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group2", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -3077,7 +3077,7 @@ external_link_move(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/dst")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group3", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -3167,7 +3167,7 @@ external_link_ride(hid_t fapl, hbool_t new_format)
/* Create enough objects in the root group to change it into a "dense" group */
for(u = 0; u < (max_compact + 1); u++) {
sprintf(objname, "filler %u", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
} /* end for */
@@ -3203,7 +3203,7 @@ external_link_ride(hid_t fapl, hbool_t new_format)
if((fid = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create object to link to */
- if((gid = H5Gcreate(fid, "dst", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "dst", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Close file */
@@ -3222,7 +3222,7 @@ external_link_ride(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/dst")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -3257,7 +3257,7 @@ external_link_ride(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/dst")) TEST_ERROR
/* Create object in external file */
- if((gid2 = H5Gcreate(gid, "new_group2", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group in external file */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -3373,7 +3373,7 @@ external_link_closing(hid_t fapl, hbool_t new_format)
if(H5Fclose(fid2) < 0) TEST_ERROR
/* Test creating each kind of object */
- if((gid = H5Gcreate(fid1, "elink/elink/elink/group1", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/elink/elink/group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Tcommit(fid1, "elink/elink/elink/type1", tid) < 0) TEST_ERROR
if((did = H5Dcreate(fid1, "elink/elink/elink/dataset1", tid2, sid, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close objects */
@@ -3435,7 +3435,7 @@ external_link_closing(hid_t fapl, hbool_t new_format)
if(H5Dclose(did) < 0) TEST_ERROR
/* Test H5Fmount */
- if((gid = H5Gcreate(fid1, "elink/elink/elink/mnt", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/elink/elink/mnt", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
H5E_BEGIN_TRY {
if(H5Fmount(fid1, "elink/elink/elink/mnt", fid1, H5P_DEFAULT) >= 0) TEST_ERROR
@@ -3462,15 +3462,15 @@ external_link_closing(hid_t fapl, hbool_t new_format)
if(H5Fclose(fid2) < 0) TEST_ERROR
/* Do an external link traversal that recursively calls another external link. */
- if((gid = H5Gcreate(fid1, "elink/elink2/group2", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/elink2/group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Create two more groups so that the last three elements in the path are
* all within the same external file
*/
- if((gid = H5Gcreate(fid1, "elink/elink2/group2/group3", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/elink2/group2/group3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid1, "elink/elink2/group2/group3/group4", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/elink2/group2/group3/group4", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
if(H5Gget_objinfo(fid1, "elink/elink2/group2/group3/group4", TRUE, &sb) < 0) TEST_ERROR
@@ -3484,12 +3484,12 @@ external_link_closing(hid_t fapl, hbool_t new_format)
* slink points to (file2)/elink2, which points to (file3)/elink, which
* points to file 4.
*/
- if((gid = H5Gcreate(fid1, "elink/file2group1/file2group2/slink/group3", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/file2group1/file2group2/slink/group3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
if(H5Lget_info(fid1, "elink/file2group1/file2group2/slink/group3", &li, H5P_DEFAULT) < 0) TEST_ERROR
/* Some simpler tests */
- if((gid = H5Gcreate(fid1, "elink/file2group3", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid1, "elink/file2group3", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
if(H5Lget_info(fid1, "elink/file2group3", &li, H5P_DEFAULT) < 0) TEST_ERROR
if(H5Lget_info(fid1, "elink/elink", &li, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3664,19 +3664,19 @@ external_link_strong(hid_t fapl, hbool_t new_format)
/* Create a group at /A/B/C in first file */
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, my_fapl)) < 0) TEST_ERROR
- if((gid1 = H5Gcreate(fid1, "A", (size_t)0)) < 0) TEST_ERROR
+ if((gid1 = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid1) < 0) TEST_ERROR
- if((gid1 = H5Gcreate(fid1, "A/B", (size_t)0)) < 0) TEST_ERROR
+ if((gid1 = H5Gcreate2(fid1, "A/B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid1) < 0) TEST_ERROR
- if((gid1 = H5Gcreate(fid1, "A/B/C", (size_t)0)) < 0) TEST_ERROR
+ if((gid1 = H5Gcreate2(fid1, "A/B/C", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid1) < 0) TEST_ERROR
if(H5Fclose(fid1) < 0) TEST_ERROR
/* Create an external link /W/X/DLINK in second file to <filename1>:/A/B/C */
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
- if((gid2 = H5Gcreate(fid2, "/W", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(fid2, "/W", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
- if((gid2 = H5Gcreate(fid2, "/W/X", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(fid2, "/W/X", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Lcreate_external(filename1, "/A/B/C", gid2, "DLINK", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
if(H5Fclose(fid2) < 0) TEST_ERROR
@@ -3892,7 +3892,7 @@ ud_hard_links(hid_t fapl)
if(H5Lis_registered(UD_HARD_TYPE) != TRUE) TEST_ERROR
/* Create a group for the UD hard link to point to */
- if((gid = H5Gcreate(fid, "group", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Get address for the group to give to the hard link */
if(H5Lget_info(fid, "group", &li, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3916,7 +3916,7 @@ ud_hard_links(hid_t fapl)
if(HDstrcmp(objname, "/group")) TEST_ERROR
/* Create object in group */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close groups*/
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -4057,7 +4057,7 @@ ud_link_reregister(hid_t fapl)
if(H5Lis_registered(UD_HARD_TYPE) != TRUE) TEST_ERROR
/* Point a UD defined hard link to a group in the same way as the previous test */
- if((gid = H5Gcreate(fid, "group", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if (H5Lget_info(fid, "group", &li, H5P_DEFAULT) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
@@ -4066,7 +4066,7 @@ ud_link_reregister(hid_t fapl)
TEST_ERROR
/* Create a group named REREG_TARGET_NAME in the same group as the ud link */
- if((gid = H5Gcreate(fid, REREG_TARGET_NAME, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, REREG_TARGET_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Now unregister UD hard links */
@@ -4103,7 +4103,7 @@ ud_link_reregister(hid_t fapl)
if(HDstrcmp(objname, "/" REREG_TARGET_NAME)) TEST_ERROR
/* Create object in group */
- if((gid2 = H5Gcreate(gid, "new_group", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close groups*/
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -4339,7 +4339,7 @@ ud_callbacks(hid_t fapl, hbool_t new_format)
if(H5Lis_registered(UD_CB_TYPE) != TRUE) TEST_ERROR
/* Create a group for the UD link to point to */
- if((gid = H5Gcreate(fid, UD_CB_TARGET, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, UD_CB_TARGET, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create a user-defined link to the group. These UD links behave like soft links. */
if(H5Lcreate_ud(fid, UD_CB_LINK_NAME, UD_CB_TYPE, ud_target_name, (size_t)UD_CB_TARGET_LEN, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4506,9 +4506,9 @@ lapl_udata(hid_t fapl, hbool_t new_format)
if(H5Lunregister(UD_CB_TYPE) < 0) TEST_ERROR
/* Create two groups for the UD link to point to */
- if((gid = H5Gcreate(fid, "group_a", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group_a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "group_b", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group_b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Create a user-defined link to the group. These UD links have no udata. */
@@ -4525,7 +4525,7 @@ lapl_udata(hid_t fapl, hbool_t new_format)
/* Try opening group through UD link */
if((gid = H5Oopen(fid, "ud_link", plist_id)) < 0) TEST_ERROR
- if((gid2 = H5Gcreate(gid, "subgroup_a", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "subgroup_a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
@@ -4539,7 +4539,7 @@ lapl_udata(hid_t fapl, hbool_t new_format)
/* Create a subgroup */
if((gid = H5Oopen(fid, "ud_link", plist_id)) < 0) TEST_ERROR
- if((gid2 = H5Gcreate(gid, "subgroup_b", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "subgroup_b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
@@ -4806,7 +4806,7 @@ ud_link_errors(hid_t fapl, hbool_t new_format)
if(H5Lregister(UD_cbfail_class1) < 0) TEST_ERROR
/* Create a group for the UD link to point to */
- if((gid = H5Gcreate(fid, "group", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Create a user-defined link to the group. */
@@ -4928,7 +4928,7 @@ lapl_nlinks(hid_t fapl, hbool_t new_format)
if((fid=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group with short name in file (used as target for links) */
- if((gid=H5Gcreate (fid, "final", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "final", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create chain of soft links to existing object (limited) */
if(H5Glink2(fid, "final", H5G_LINK_SOFT, fid, "soft1") < 0) TEST_ERROR
@@ -4976,7 +4976,7 @@ lapl_nlinks(hid_t fapl, hbool_t new_format)
if(HDstrcmp(objname, "/soft17")) TEST_ERROR
/* Create group using soft link */
- if((gid2 = H5Gcreate(gid, "new_soft", (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, "new_soft", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close groups */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -5167,7 +5167,7 @@ linkinfo(hid_t fapl, hbool_t new_format)
/* Create an object of each type */
if((tid = H5Tcopy(H5T_NATIVE_INT)) < 0) TEST_ERROR
if(H5Tcommit(fid, "datatype", tid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid, "group", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Glink(fid, H5G_LINK_SOFT, "group", "softlink") < 0) TEST_ERROR
if((sid = H5Screate(H5S_SCALAR)) < 0) TEST_ERROR
@@ -5429,7 +5429,7 @@ corder_create_compact(hid_t fapl)
/* Create several links, but keep group in compact form */
for(u = 0; u < max_compact; u++) {
sprintf(objname, "filler %u", u);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify state of group */
@@ -5549,7 +5549,7 @@ corder_create_dense(hid_t fapl)
/* Create several links, up to limit of compact form */
for(u = 0; u < max_compact; u++) {
sprintf(objname, "filler %u", u);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify state of group */
@@ -5561,7 +5561,7 @@ corder_create_dense(hid_t fapl)
/* Create another link, to push group into dense form */
sprintf(objname, "filler %u", max_compact);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify state of group */
@@ -5703,13 +5703,13 @@ corder_transition(hid_t fapl)
/* Create several links, up to limit of compact form */
for(u = 0; u < max_compact; u++) {
sprintf(objname, "filler %u", u);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end for */
/* Create another link, to push group into dense form */
sprintf(objname, "filler %u", max_compact);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify state of group */
@@ -5749,7 +5749,7 @@ corder_transition(hid_t fapl)
/* Re-add links to get back into dense form */
for(u = (min_dense - 1); u < (max_compact + 1); u++) {
sprintf(objname, "filler %u", u);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end for */
@@ -5812,7 +5812,7 @@ corder_transition(hid_t fapl)
/* Re-add links to get back into dense form */
for(u = (min_dense - 1); u < (max_compact + 1); u++) {
sprintf(objname, "filler %u", u);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end for */
@@ -5929,7 +5929,7 @@ corder_delete(hid_t fapl)
/* Create links until the group is in dense form */
for(u = 0; u < max_compact * 2; u++) {
sprintf(objname, "filler %u", u);
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) FAIL_STACK_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
if(H5Gclose(group_id2) < 0) FAIL_STACK_ERROR
} /* end for */
@@ -6227,7 +6227,7 @@ link_info_by_idx(hid_t fapl)
hid_t group_id2; /* Group ID */
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end if */
else {
@@ -6269,7 +6269,7 @@ link_info_by_idx(hid_t fapl)
hid_t group_id2; /* Group ID */
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end if */
else {
@@ -6368,7 +6368,7 @@ link_info_by_idx_old(hid_t fapl)
if((file_id = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group to operate on */
- if((group_id = H5Gcreate(file_id, CORDER_GROUP_NAME, (size_t)0)) < 0) TEST_ERROR
+ if((group_id = H5Gcreate2(file_id, CORDER_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create several links */
for(u = 0; u < CORDER_NLINKS; u++) {
@@ -6380,7 +6380,7 @@ link_info_by_idx_old(hid_t fapl)
H5G_stat_t sb; /* Buffer for querying object's info */
/* Create group */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Gget_objinfo(group_id2, ".", FALSE, &sb) < 0) TEST_ERROR
@@ -6598,7 +6598,7 @@ delete_by_idx(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify link information for new link */
@@ -6653,7 +6653,7 @@ delete_by_idx(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify state of group (dense) */
@@ -6720,7 +6720,7 @@ delete_by_idx(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
/* Verify state of group (dense) */
@@ -6857,7 +6857,7 @@ delete_by_idx_old(hid_t fapl)
if((file_id = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group to operate on */
- if((group_id = H5Gcreate(file_id, CORDER_GROUP_NAME, (size_t)0)) < 0) TEST_ERROR
+ if((group_id = H5Gcreate2(file_id, CORDER_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Delete links from one end */
@@ -6877,7 +6877,7 @@ delete_by_idx_old(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create group */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Gget_objinfo(group_id2, ".", FALSE, &sb) < 0) TEST_ERROR
@@ -6954,7 +6954,7 @@ delete_by_idx_old(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create group */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Gget_objinfo(group_id2, ".", FALSE, &sb) < 0) TEST_ERROR
@@ -7445,7 +7445,7 @@ link_iterate(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end for */
@@ -7471,7 +7471,7 @@ link_iterate(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end for */
@@ -7826,7 +7826,7 @@ link_iterate_old(hid_t fapl)
if((file_id = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group with creation order tracking on */
- if((group_id = H5Gcreate(file_id, CORDER_GROUP_NAME, (size_t)0)) < 0) TEST_ERROR
+ if((group_id = H5Gcreate2(file_id, CORDER_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check for iteration on empty group */
@@ -7841,7 +7841,7 @@ link_iterate_old(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(group_id2) < 0) TEST_ERROR
} /* end for */
@@ -8142,7 +8142,7 @@ open_by_idx(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Gget_objinfo(group_id2, ".", FALSE, &sb) < 0) TEST_ERROR
@@ -8181,7 +8181,7 @@ open_by_idx(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Gget_objinfo(group_id2, ".", FALSE, &sb) < 0) TEST_ERROR
@@ -8327,7 +8327,7 @@ open_by_idx_old(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Gget_objinfo(group_id2, ".", FALSE, &sb) < 0) TEST_ERROR
@@ -8595,7 +8595,7 @@ object_info(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Oget_info(group_id2, ".", &oinfo, H5P_DEFAULT) < 0) TEST_ERROR
@@ -8643,7 +8643,7 @@ object_info(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Oget_info(group_id2, ".", &oinfo, H5P_DEFAULT) < 0) TEST_ERROR
@@ -8792,7 +8792,7 @@ object_info_old(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's address on disk */
if(H5Oget_info(group_id2, ".", &oinfo, H5P_DEFAULT) < 0) TEST_ERROR
@@ -8999,7 +8999,7 @@ group_info(hid_t fapl)
sprintf(objname2, "filler %02u", v);
/* Create hard link, with group object */
- if((group_id3 = H5Gcreate(group_id2, objname2, (size_t)0)) < 0) TEST_ERROR
+ if((group_id3 = H5Gcreate2(group_id2, objname2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group created */
if(H5Gclose(group_id3) < 0) TEST_ERROR
@@ -9088,7 +9088,7 @@ group_info(hid_t fapl)
sprintf(objname2, "filler %02u", v);
/* Create hard link, with group object */
- if((group_id3 = H5Gcreate(group_id2, objname2, (size_t)0)) < 0) TEST_ERROR
+ if((group_id3 = H5Gcreate2(group_id2, objname2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group created */
if(H5Gclose(group_id3) < 0) TEST_ERROR
@@ -9250,7 +9250,7 @@ group_info_old(hid_t fapl)
sprintf(objname, "filler %02u", u);
/* Create hard link, with group object */
- if((group_id2 = H5Gcreate(group_id, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group_id2 = H5Gcreate2(group_id, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Retrieve group's information */
if(H5Gget_info(group_id2, ".", &grp_info, H5P_DEFAULT) < 0) TEST_ERROR
@@ -9266,7 +9266,7 @@ group_info_old(hid_t fapl)
sprintf(objname2, "filler %02u", v);
/* Create hard link, with group object */
- if((group_id3 = H5Gcreate(group_id2, objname2, (size_t)0)) < 0) TEST_ERROR
+ if((group_id3 = H5Gcreate2(group_id2, objname2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close group created */
if(H5Gclose(group_id3) < 0) TEST_ERROR
diff --git a/test/mount.c b/test/mount.c
index 6a8dc1e..11c769d 100644
--- a/test/mount.c
+++ b/test/mount.c
@@ -61,40 +61,37 @@ int bm[NX][NY], bm_out[NX][NY]; /* Data buffers */
static int
setup(hid_t fapl)
{
- hid_t file=-1;
+ hid_t file = -1;
char filename[1024];
/* file 1 */
h5_fixname(FILENAME[0], fapl, filename, sizeof filename);
- if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0)
- goto error;
- if (H5Gclose(H5Gcreate(file, "/mnt1", (size_t)0))<0) goto error;
- if (H5Gclose(H5Gcreate(file, "/mnt1/file1", (size_t)0))<0) goto error;
- if (H5Gclose(H5Gcreate(file, "/mnt_unlink", (size_t)0))<0) goto error;
- if (H5Gclose(H5Gcreate(file, "/mnt_move_a", (size_t)0))<0) goto error;
- if (H5Glink(file, H5L_TYPE_HARD, "/mnt1/file1", "/file1")<0) goto error;
- if (H5Glink(file, H5L_TYPE_HARD, "/mnt1", "/mnt1_link")<0) goto error;
- if (H5Fclose(file)<0) goto error;
+ if((file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/mnt1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/mnt1/file1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/mnt_unlink", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/mnt_move_a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Glink(file, H5L_TYPE_HARD, "/mnt1/file1", "/file1") < 0) FAIL_STACK_ERROR
+ if(H5Glink(file, H5L_TYPE_HARD, "/mnt1", "/mnt1_link") < 0) FAIL_STACK_ERROR
+ if(H5Fclose(file) < 0) FAIL_STACK_ERROR
/* file 2 */
h5_fixname(FILENAME[1], fapl, filename, sizeof filename);
- if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0)
- goto error;
- if (H5Gclose(H5Gcreate(file, "/file2", (size_t)0))<0) goto error;
- if (H5Gclose(H5Gcreate(file, "/rename_a", (size_t)0))<0) goto error;
- if (H5Gclose(H5Gcreate(file, "/rename_b", (size_t)0))<0) goto error;
- if (H5Gclose(H5Gcreate(file, "/rename_a/x", (size_t)0))<0) goto error;
- if (H5Fclose(file)<0) goto error;
+ if((file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/file2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/rename_a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/rename_b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Gclose(H5Gcreate2(file, "/rename_a/x", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
+ if(H5Fclose(file) < 0) FAIL_STACK_ERROR
/* file 3 */
h5_fixname(FILENAME[2], fapl, filename, sizeof filename);
- if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl))<0)
- goto error;
- if (H5Fclose(file)<0) goto error;
+ if((file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+ if(H5Fclose(file) < 0) FAIL_STACK_ERROR
return 0;
- error:
+error:
H5E_BEGIN_TRY {
H5Fclose(file);
} H5E_END_TRY;
@@ -1103,11 +1100,11 @@ test_mount_after_close(hid_t fapl)
*/
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidAB = H5Gcreate(gidA , "B", (size_t)0)) < 0)
+ if((gidAB = H5Gcreate2(gidA, "B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidABM = H5Gcreate(gidAB , "M", (size_t)0)) < 0) /* Mount point */
+ if((gidABM = H5Gcreate2(gidAB, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) /* Mount point */
TEST_ERROR
if(H5Glink(gidAB, H5L_TYPE_SOFT, "./M/X/Y", "C") < 0) /* Soft link */
TEST_ERROR
@@ -1139,9 +1136,9 @@ test_mount_after_close(hid_t fapl)
if((sid = H5Screate_simple(RANK, dims, NULL)) < 0)
TEST_ERROR
- if((gidX = H5Gcreate(fid2, "/X", (size_t)0)) < 0)
+ if((gidX = H5Gcreate2(fid2, "/X", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidXY = H5Gcreate(gidX, "Y", (size_t)0)) < 0)
+ if((gidXY = H5Gcreate2(gidX, "Y", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if((did = H5Dcreate(gidXY, "D", H5T_NATIVE_INT, sid, H5P_DEFAULT)) < 0)
TEST_ERROR
@@ -1322,17 +1319,17 @@ test_mount_after_unmount(hid_t fapl)
/* Create first file and some groups in it. */
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidAM = H5Gcreate(gidA, "M", (size_t)0)) < 0)
+ if((gidAM = H5Gcreate2(gidA, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidAM) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
TEST_ERROR
- if((gidB = H5Gcreate(fid1, "B", (size_t)0)) < 0)
+ if((gidB = H5Gcreate2(fid1, "B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidBM = H5Gcreate(gidB, "M", (size_t)0)) < 0)
+ if((gidBM = H5Gcreate2(gidB, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidBM) < 0)
TEST_ERROR
@@ -1344,13 +1341,13 @@ test_mount_after_unmount(hid_t fapl)
/* Create second file and a group in it. */
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
TEST_ERROR
- if((gidX = H5Gcreate(fid2, "/X", (size_t)0)) < 0)
+ if((gidX = H5Gcreate2(fid2, "/X", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidXM = H5Gcreate(gidX, "M", (size_t)0)) < 0)
+ if((gidXM = H5Gcreate2(gidX, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidXM) < 0)
TEST_ERROR
- if((gidXX = H5Gcreate(gidX, "X", (size_t)0)) < 0)
+ if((gidXX = H5Gcreate2(gidX, "X", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidXX) < 0)
TEST_ERROR
@@ -1362,7 +1359,7 @@ test_mount_after_unmount(hid_t fapl)
/* Create third file and a group in it. */
if((fid3 = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
TEST_ERROR
- if((gidY = H5Gcreate(fid3, "/Y", (size_t)0)) < 0)
+ if((gidY = H5Gcreate2(fid3, "/Y", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidY) < 0)
TEST_ERROR
@@ -1372,7 +1369,7 @@ test_mount_after_unmount(hid_t fapl)
/* Create fourth file and a group in it. */
if((fid4 = H5Fcreate(filename4, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
TEST_ERROR
- if((gidZ = H5Gcreate(fid4, "/Z", (size_t)0)) < 0)
+ if((gidZ = H5Gcreate2(fid4, "/Z", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidZ) < 0)
TEST_ERROR
@@ -1583,7 +1580,7 @@ test_missing_unmount(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -1597,7 +1594,7 @@ test_missing_unmount(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidE = H5Gcreate(fid2, "E", (size_t)0)) < 0)
+ if((gidE = H5Gcreate2(fid2, "E", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidE) < 0)
@@ -1611,7 +1608,7 @@ test_missing_unmount(hid_t fapl)
if((fid3 = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid3, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid3, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -1737,7 +1734,7 @@ test_hold_open_file(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -1751,7 +1748,7 @@ test_hold_open_file(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -1870,7 +1867,7 @@ test_hold_open_group(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -1884,7 +1881,7 @@ test_hold_open_group(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -2031,7 +2028,7 @@ test_fcdegree_same(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -2045,7 +2042,7 @@ test_fcdegree_same(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -2176,7 +2173,7 @@ test_fcdegree_semi(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -2190,7 +2187,7 @@ test_fcdegree_semi(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -2318,7 +2315,7 @@ test_fcdegree_strong(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -2332,7 +2329,7 @@ test_fcdegree_strong(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -2461,7 +2458,7 @@ test_acc_perm(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -2475,7 +2472,7 @@ test_acc_perm(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -2529,24 +2526,24 @@ test_acc_perm(hid_t fapl)
/* Attempt to create objects in read only file (should fail) */
H5E_BEGIN_TRY {
- bad_id = H5Gcreate(gidAM, "Z", (size_t)0);
+ bad_id = H5Gcreate2(gidAM, "Z", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
if(bad_id >= 0)
TEST_ERROR
H5E_BEGIN_TRY {
- bad_id = H5Gcreate(fid1, "/A/L", (size_t)0);
+ bad_id = H5Gcreate2(fid1, "/A/L", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
if(bad_id >= 0)
TEST_ERROR
/* Attempt to create objects in read/write file (should succeed) */
- if((gidB = H5Gcreate(fid2, "/B", (size_t)0)) < 0)
+ if((gidB = H5Gcreate2(fid2, "/B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidB) < 0)
TEST_ERROR
/* (Note that this object should get created in the "hidden" group for "A" in parent file) */
- if((gidC = H5Gcreate(gidA, "C", (size_t)0)) < 0)
+ if((gidC = H5Gcreate2(gidA, "C", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidC) < 0)
TEST_ERROR
@@ -2560,7 +2557,7 @@ test_acc_perm(hid_t fapl)
TEST_ERROR
/* Attempt to create objects in read/write file (should succeed) */
- if((gidAMZ = H5Gcreate(fid1, "/A/M/Z", (size_t)0)) < 0)
+ if((gidAMZ = H5Gcreate2(fid1, "/A/M/Z", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
/* Get and verify file name */
@@ -2576,7 +2573,7 @@ test_acc_perm(hid_t fapl)
/* Attempt to create objects in read only file again (should fail) */
H5E_BEGIN_TRY {
- bad_id = H5Gcreate(fid1, "/A/L", (size_t)0);
+ bad_id = H5Gcreate2(fid1, "/A/L", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
if(bad_id >= 0)
TEST_ERROR
@@ -2666,13 +2663,13 @@ test_mult_mount(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
TEST_ERROR
- if((gidB = H5Gcreate(fid1, "B", (size_t)0)) < 0)
+ if((gidB = H5Gcreate2(fid1, "B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidB) < 0)
@@ -2686,13 +2683,13 @@ test_mult_mount(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
TEST_ERROR
- if((gidN = H5Gcreate(fid2, "N", (size_t)0)) < 0)
+ if((gidN = H5Gcreate2(fid2, "N", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidN) < 0)
@@ -2706,13 +2703,13 @@ test_mult_mount(hid_t fapl)
if((fid3 = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidS = H5Gcreate(fid3, "S", (size_t)0)) < 0)
+ if((gidS = H5Gcreate2(fid3, "S", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidS) < 0)
TEST_ERROR
- if((gidT = H5Gcreate(fid3, "T", (size_t)0)) < 0)
+ if((gidT = H5Gcreate2(fid3, "T", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidT) < 0)
@@ -2770,7 +2767,7 @@ test_mult_mount(hid_t fapl)
TEST_ERROR
/* Create object in file #3 */
- if((gidU = H5Gcreate(gidAMT, "U", (size_t)0)) < 0)
+ if((gidU = H5Gcreate2(gidAMT, "U", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidU) < 0)
@@ -2894,7 +2891,7 @@ test_nested_survive(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -2908,7 +2905,7 @@ test_nested_survive(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -2922,7 +2919,7 @@ test_nested_survive(hid_t fapl)
if((fid3 = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidS = H5Gcreate(fid3, "S", (size_t)0)) < 0)
+ if((gidS = H5Gcreate2(fid3, "S", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidS) < 0)
@@ -3104,7 +3101,7 @@ test_close_parent(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
@@ -3118,7 +3115,7 @@ test_close_parent(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid2, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid2, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
@@ -3295,12 +3292,12 @@ test_cut_graph(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
TEST_ERROR
- if((gidB = H5Gcreate(fid1, "B", (size_t)0)) < 0)
+ if((gidB = H5Gcreate2(fid1, "B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidB) < 0)
TEST_ERROR
@@ -3313,12 +3310,12 @@ test_cut_graph(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidD = H5Gcreate(fid2, "D", (size_t)0)) < 0)
+ if((gidD = H5Gcreate2(fid2, "D", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidD) < 0)
TEST_ERROR
- if((gidE = H5Gcreate(fid2, "E", (size_t)0)) < 0)
+ if((gidE = H5Gcreate2(fid2, "E", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidE) < 0)
TEST_ERROR
@@ -3331,12 +3328,12 @@ test_cut_graph(hid_t fapl)
if((fid3 = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidH = H5Gcreate(fid3, "H", (size_t)0)) < 0)
+ if((gidH = H5Gcreate2(fid3, "H", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidH) < 0)
TEST_ERROR
- if((gidI = H5Gcreate(fid3, "I", (size_t)0)) < 0)
+ if((gidI = H5Gcreate2(fid3, "I", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidI) < 0)
TEST_ERROR
@@ -3348,7 +3345,7 @@ test_cut_graph(hid_t fapl)
if((fid4 = H5Fcreate(filename4, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidK = H5Gcreate(fid4, "K", (size_t)0)) < 0)
+ if((gidK = H5Gcreate2(fid4, "K", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidK) < 0)
TEST_ERROR
@@ -3360,7 +3357,7 @@ test_cut_graph(hid_t fapl)
if((fid5 = H5Fcreate(filename5, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidM = H5Gcreate(fid5, "M", (size_t)0)) < 0)
+ if((gidM = H5Gcreate2(fid5, "M", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidM) < 0)
TEST_ERROR
@@ -3372,7 +3369,7 @@ test_cut_graph(hid_t fapl)
if((fid6 = H5Fcreate(filename6, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidO = H5Gcreate(fid6, "O", (size_t)0)) < 0)
+ if((gidO = H5Gcreate2(fid6, "O", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidO) < 0)
TEST_ERROR
@@ -3384,7 +3381,7 @@ test_cut_graph(hid_t fapl)
if((fid7 = H5Fcreate(filename7, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidQ = H5Gcreate(fid7, "Q", (size_t)0)) < 0)
+ if((gidQ = H5Gcreate2(fid7, "Q", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidQ) < 0)
TEST_ERROR
@@ -3676,12 +3673,12 @@ test_symlink(hid_t fapl)
if((fid1 = H5Fcreate(filename1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidA = H5Gcreate(fid1, "A", (size_t)0)) < 0)
+ if((gidA = H5Gcreate2(fid1, "A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidA) < 0)
TEST_ERROR
- if((gidB = H5Gcreate(fid1, "B", (size_t)0)) < 0)
+ if((gidB = H5Gcreate2(fid1, "B", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidB) < 0)
TEST_ERROR
@@ -3698,12 +3695,12 @@ test_symlink(hid_t fapl)
if((fid2 = H5Fcreate(filename2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidD = H5Gcreate(fid2, "D", (size_t)0)) < 0)
+ if((gidD = H5Gcreate2(fid2, "D", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidD) < 0)
TEST_ERROR
- if((gidE = H5Gcreate(fid2, "E", (size_t)0)) < 0)
+ if((gidE = H5Gcreate2(fid2, "E", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidE) < 0)
TEST_ERROR
@@ -3716,12 +3713,12 @@ test_symlink(hid_t fapl)
if((fid3 = H5Fcreate(filename3, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
- if((gidH = H5Gcreate(fid3, "H", (size_t)0)) < 0)
+ if((gidH = H5Gcreate2(fid3, "H", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidH) < 0)
TEST_ERROR
- if((gidI = H5Gcreate(fid3, "I", (size_t)0)) < 0)
+ if((gidI = H5Gcreate2(fid3, "I", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0)
TEST_ERROR
if(H5Gclose(gidI) < 0)
TEST_ERROR
diff --git a/test/ntypes.c b/test/ntypes.c
index 097b032..a842ddb 100644
--- a/test/ntypes.c
+++ b/test/ntypes.c
@@ -1906,8 +1906,7 @@ test_refer_dtype(hid_t file)
TEST_ERROR;
/* Create a group */
- if((group=H5Gcreate(file,"Group1",(size_t)-1))<0)
- TEST_ERROR;
+ if((group = H5Gcreate2(file, "Group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR
/* Create a datatype to refer to */
if((tid1 = H5Tcreate (H5T_COMPOUND, sizeof(s1_t)))<0)
diff --git a/test/objcopy.c b/test/objcopy.c
index 105de75..32b0995 100755
--- a/test/objcopy.c
+++ b/test/objcopy.c
@@ -1464,7 +1464,7 @@ test_copy_named_datatype(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the datatype from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATATYPE_SIMPLE, fid_dst, NAME_DATATYPE_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -1557,7 +1557,7 @@ test_copy_named_datatype_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the datatype from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATATYPE_VL, fid_dst, NAME_DATATYPE_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -1656,7 +1656,7 @@ test_copy_named_datatype_vl_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the datatype from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATATYPE_VL_VL, fid_dst, NAME_DATATYPE_VL_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -1773,7 +1773,7 @@ test_copy_dataset_simple(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -1880,7 +1880,7 @@ test_copy_dataset_simple_empty(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2010,7 +2010,7 @@ test_copy_dataset_compound(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_COMPOUND, fid_dst, NAME_DATASET_COMPOUND, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2138,7 +2138,7 @@ test_copy_dataset_chunked(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2255,7 +2255,7 @@ test_copy_dataset_chunked_empty(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2393,7 +2393,7 @@ test_copy_dataset_chunked_sparse(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2526,7 +2526,7 @@ test_copy_dataset_compressed(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2654,7 +2654,7 @@ test_copy_dataset_compact(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_COMPACT, fid_dst, NAME_DATASET_COMPACT, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2781,7 +2781,7 @@ test_copy_dataset_external(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_EXTERNAL, fid_dst, NAME_DATASET_EXTERNAL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2902,7 +2902,7 @@ test_copy_dataset_named_dtype(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_NAMED_DTYPE, fid_dst, NAME_DATASET_NAMED_DTYPE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2989,7 +2989,7 @@ test_copy_dataset_named_dtype_hier(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* Create group to place all objects in */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Set dataspace dimensions */
dim1d[0]=DIM_SIZE_1;
@@ -3039,7 +3039,7 @@ test_copy_dataset_named_dtype_hier(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3128,7 +3128,7 @@ test_copy_dataset_named_dtype_hier_outside(hid_t fcpl_src, hid_t fcpl_dst, hid_t
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* Create group to place all objects in */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Set dataspace dimensions */
dim1d[0]=DIM_SIZE_1;
@@ -3178,7 +3178,7 @@ test_copy_dataset_named_dtype_hier_outside(hid_t fcpl_src, hid_t fcpl_dst, hid_t
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3266,7 +3266,7 @@ test_copy_dataset_multi_ohdr_chunks(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* Create group to place all objects in */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Set dataspace dimensions */
dim1d[0]=DIM_SIZE_1;
@@ -3312,7 +3312,7 @@ test_copy_dataset_multi_ohdr_chunks(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3400,7 +3400,7 @@ test_copy_dataset_attr_named_dtype(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* Create group to place all objects in */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Set dataspace dimensions */
dim1d[0]=DIM_SIZE_1;
@@ -3453,7 +3453,7 @@ test_copy_dataset_attr_named_dtype(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3573,7 +3573,7 @@ test_copy_dataset_contig_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3711,7 +3711,7 @@ test_copy_dataset_chunked_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3848,7 +3848,7 @@ test_copy_dataset_compact_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -3968,7 +3968,7 @@ test_copy_attribute_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_SIMPLE, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4111,7 +4111,7 @@ test_copy_dataset_compressed_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_CHUNKED, fid_dst, NAME_DATASET_CHUNKED, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4203,7 +4203,7 @@ test_copy_group_empty(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_EMPTY, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_EMPTY, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -4222,7 +4222,7 @@ test_copy_group_empty(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_EMPTY, fid_dst, NAME_GROUP_EMPTY, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4309,7 +4309,7 @@ test_copy_group(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -4332,11 +4332,11 @@ test_copy_group(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if(H5Dclose(did) < 0) TEST_ERROR
/* create a sub-group */
- if((gid_sub = H5Gcreate(fid_src, NAME_GROUP_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(fid_src, NAME_GROUP_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if( H5Gclose(gid_sub) < 0) TEST_ERROR
/* create another sub-group */
- if((gid_sub = H5Gcreate(fid_src, NAME_GROUP_SUB_2, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(fid_src, NAME_GROUP_SUB_2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if( H5Gclose(gid_sub) < 0) TEST_ERROR
/* close the group */
@@ -4353,7 +4353,7 @@ test_copy_group(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4443,7 +4443,7 @@ test_copy_root_group(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -4466,11 +4466,11 @@ test_copy_root_group(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if(H5Dclose(did) < 0) TEST_ERROR
/* create a sub-group */
- if((gid_sub = H5Gcreate(fid_src, NAME_GROUP_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(fid_src, NAME_GROUP_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid_sub) < 0) TEST_ERROR
/* create another sub-group */
- if((gid_sub = H5Gcreate(fid_src, NAME_GROUP_SUB_2, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(fid_src, NAME_GROUP_SUB_2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid_sub) < 0) TEST_ERROR
/* close the group */
@@ -4486,7 +4486,7 @@ test_copy_root_group(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, "/", fid_dst, "/root_from_src", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4575,7 +4575,7 @@ test_copy_group_deep(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -4590,11 +4590,11 @@ test_copy_group_deep(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
/* create nested sub-groups & datasets */
for(i = 0; i < NUM_SUB_GROUPS; i++) {
sprintf(objname, "Group #%d", i);
- if((gid_sub = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
for(j = 0; j < NUM_SUB_GROUPS; j++) {
sprintf(objname, "Group #%d", j);
- if((gid_sub2 = H5Gcreate(gid_sub, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub2 = H5Gcreate2(gid_sub, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
for(k = 0; k < NUM_DATASETS; k++) {
sprintf(objname, "Dataset #%d", k);
@@ -4628,7 +4628,7 @@ test_copy_group_deep(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4706,15 +4706,15 @@ test_copy_group_loop(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
/* create sub-groups */
- if((gid_sub = H5Gcreate(gid, NAME_GROUP_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(gid, NAME_GROUP_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
- if((gid_sub2 = H5Gcreate(gid, NAME_GROUP_SUB_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub2 = H5Gcreate2(gid, NAME_GROUP_SUB_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create link to top group */
if(H5Glink2(gid, ".", H5L_TYPE_HARD, gid_sub2, NAME_GROUP_LOOP) < 0) TEST_ERROR
@@ -4739,7 +4739,7 @@ test_copy_group_loop(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4823,7 +4823,7 @@ test_copy_group_wide_loop(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -4831,11 +4831,11 @@ test_copy_group_wide_loop(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
/* create wide sub-group hierarchy, with multiple links to higher groups */
for(u = 0; u < NUM_WIDE_LOOP_GROUPS; u++) {
sprintf(objname, "%s-%u", NAME_GROUP_SUB, u);
- if((gid_sub = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
for(v = 0; v < NUM_WIDE_LOOP_GROUPS; v++) {
sprintf(objname, "%s-%u", NAME_GROUP_SUB_SUB2, v);
- if((gid_sub2 = H5Gcreate(gid_sub, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub2 = H5Gcreate2(gid_sub, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create link to top group */
if(H5Glink2(gid, ".", H5L_TYPE_HARD, gid_sub2, NAME_GROUP_LOOP) < 0) TEST_ERROR
@@ -4868,7 +4868,7 @@ test_copy_group_wide_loop(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_TOP, fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -4956,7 +4956,7 @@ test_copy_group_links(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_LINK, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_LINK, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -5004,7 +5004,7 @@ test_copy_group_links(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the group from SRC to DST */
if(H5Ocopy(fid_src, NAME_GROUP_LINK, fid_dst, NAME_GROUP_LINK, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5091,7 +5091,7 @@ test_copy_soft_link(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_LINK, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_LINK, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -5130,7 +5130,7 @@ test_copy_soft_link(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_LINK_SOFT, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5218,7 +5218,7 @@ test_copy_ext_link(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_LINK, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_LINK, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -5245,7 +5245,7 @@ test_copy_ext_link(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_ext = H5Fcreate(ext_filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* create group in the file that will hold the external link */
- if((gid = H5Gcreate(fid_ext, NAME_GROUP_LINK, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_ext, NAME_GROUP_LINK, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create an external link to the dataset in the source file */
if(H5Lcreate_external(src_filename, NAME_LINK_DATASET, fid_ext, NAME_LINK_EXTERN, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5261,7 +5261,7 @@ test_copy_ext_link(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_ext, NAME_LINK_EXTERN, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5383,7 +5383,7 @@ test_copy_exist(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_SIMPLE,fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5492,7 +5492,7 @@ test_copy_path(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST (should fail - intermediate groups not there) */
H5E_BEGIN_TRY {
@@ -5501,13 +5501,13 @@ test_copy_path(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if( ret >= 0) TEST_ERROR
/* Create the intermediate groups in destination file */
- if((gid = H5Gcreate(fid_dst, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_dst, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid_dst, NAME_GROUP_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_dst, NAME_GROUP_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
- if((gid = H5Gcreate(fid_dst, NAME_GROUP_SUB_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_dst, NAME_GROUP_SUB_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* copy the dataset from SRC to DST, using full path */
@@ -5667,7 +5667,7 @@ test_copy_old_layout(hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_OLD_FORMAT, fid_dst, NAME_DATASET_SIMPLE, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5800,7 +5800,7 @@ test_copy_dataset_compact_named_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -5940,7 +5940,7 @@ test_copy_dataset_contig_named_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6088,7 +6088,7 @@ test_copy_dataset_chunked_named_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6238,7 +6238,7 @@ test_copy_dataset_compressed_named_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL, fid_dst, NAME_DATASET_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6394,7 +6394,7 @@ test_copy_dataset_compact_vl_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6548,7 +6548,7 @@ test_copy_dataset_contig_vl_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
/* Create an uncopied object in destination file so that addresses in source and destination files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6702,7 +6702,7 @@ test_copy_dataset_chunked_vl_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
/* create destination file */
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6859,7 +6859,7 @@ test_copy_dataset_compressed_vl_vl(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl)
/* create destination file */
if((fid_dst = H5Fcreate(dst_filename, H5F_ACC_TRUNC, fcpl_dst, fapl)) < 0) TEST_ERROR
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* copy the dataset from SRC to DST */
if(H5Ocopy(fid_src, NAME_DATASET_VL_VL, fid_dst, NAME_DATASET_VL_VL, H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -6965,7 +6965,7 @@ test_copy_option(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl, unsigned flag, hboo
if((fid_src = H5Fcreate(src_filename, H5F_ACC_TRUNC, fcpl_src, fapl)) < 0) TEST_ERROR
/* create group at the SRC file */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_TOP, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_TOP, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* attach attributes to the group */
if(test_copy_attach_attributes(gid, H5T_NATIVE_INT) < 0) TEST_ERROR
@@ -6983,7 +6983,7 @@ test_copy_option(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl, unsigned flag, hboo
if(H5Dclose(did) < 0) TEST_ERROR
/* create a sub-group */
- if((gid_sub = H5Gcreate(fid_src, NAME_GROUP_SUB, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub = H5Gcreate2(fid_src, NAME_GROUP_SUB, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* add a dataset to the sub group */
if((did = H5Dcreate(gid_sub, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT) ) < 0) TEST_ERROR
@@ -6991,7 +6991,7 @@ test_copy_option(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl, unsigned flag, hboo
if(H5Dclose(did) < 0) TEST_ERROR
/* create sub-sub-group */
- if((gid_sub_sub = H5Gcreate(gid_sub, NAME_GROUP_SUB_SUB2, (size_t)0)) < 0) TEST_ERROR
+ if((gid_sub_sub = H5Gcreate2(gid_sub, NAME_GROUP_SUB_SUB2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* add a dataset to the sub sub group */
if((did = H5Dcreate(gid_sub_sub, NAME_DATASET_SIMPLE, H5T_NATIVE_INT, sid, H5P_DEFAULT) ) < 0) TEST_ERROR
@@ -7012,20 +7012,20 @@ test_copy_option(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl, unsigned flag, hboo
if((flag & H5O_COPY_EXPAND_SOFT_LINK_FLAG) > 0) {
/* Create group to copy */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_LINK, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_LINK, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Glink(fid_src, H5L_TYPE_SOFT, NAME_DATASET_SUB_SUB, NAME_LINK_SOFT) < 0) TEST_ERROR
if(H5Glink(fid_src, H5L_TYPE_SOFT, "nowhere", NAME_LINK_SOFT_DANGLE) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
/* Create group to compare with */
- if((gid = H5Gcreate(fid_src, NAME_GROUP_LINK2, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid_src, NAME_GROUP_LINK2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Glink(fid_src, H5L_TYPE_HARD, NAME_DATASET_SUB_SUB, NAME_LINK_SOFT2) < 0) TEST_ERROR
if(H5Glink(fid_src, H5L_TYPE_SOFT, "nowhere", NAME_LINK_SOFT_DANGLE2) < 0) TEST_ERROR
if(H5Gclose(gid) < 0) TEST_ERROR
} /* end if */
if((flag & H5O_COPY_EXPAND_REFERENCE_FLAG) > 0) {
- if((gid_ref = H5Gcreate(fid_src, NAME_GROUP_REF, (size_t)0)) < 0) TEST_ERROR
+ if((gid_ref = H5Gcreate2(fid_src, NAME_GROUP_REF, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* create an attribute of object references */
if(attach_ref_attr(fid_src, gid_ref) < 0) TEST_ERROR
@@ -7058,7 +7058,7 @@ test_copy_option(hid_t fcpl_src, hid_t fcpl_dst, hid_t fapl, unsigned flag, hboo
/* Create an uncopied object in destination file so that addresses in source and destination
files aren't the same */
- if(H5Gclose(H5Gcreate(fid_dst, NAME_GROUP_UNCOPIED, (size_t)0)) < 0) TEST_ERROR
+ if(H5Gclose(H5Gcreate2(fid_dst, NAME_GROUP_UNCOPIED, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* create property to pass copy options */
if((pid = H5Pcreate(H5P_OBJECT_COPY)) < 0) TEST_ERROR
diff --git a/test/stab.c b/test/stab.c
index 1638982..5e51131 100644
--- a/test/stab.c
+++ b/test/stab.c
@@ -25,7 +25,6 @@
#include "h5test.h"
#include "H5Gpkg.h" /* Groups */
-#include "H5HLprivate.h" /* Local Heaps */
const char *FILENAME[] = {
"stab",
@@ -67,12 +66,15 @@ const char *FILENAME[] = {
#define NO_COMPACT_MAX_COMPACT 0
#define NO_COMPACT_MIN_DENSE 0
-/* Definitions for 'no_compact' test */
+/* Definitions for 'gcpl_on_root' test */
#define GCPL_ON_ROOT_MIDDLE_GROUP "/middle"
#define GCPL_ON_ROOT_BOTTOM_GROUP "/middle/bottom"
#define GCPL_ON_ROOT_MAX_COMPACT 4
#define GCPL_ON_ROOT_MIN_DENSE 2
+/* Definitions for 'old_api' test */
+#define OLD_API_GROUP "/old_api"
+
/*-------------------------------------------------------------------------
* Function: test_misc
@@ -106,9 +108,9 @@ test_misc(hid_t fapl, hbool_t new_format)
if((fid = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create initial groups for testing, then close */
- if((g1 = H5Gcreate(fid, "test_1a", (size_t)0)) < 0) TEST_ERROR
- if((g2 = H5Gcreate(g1, "sub_1", (size_t)0)) < 0) TEST_ERROR
- if((g3 = H5Gcreate(fid, "test_1b", (size_t)0)) < 0) TEST_ERROR
+ if((g1 = H5Gcreate2(fid, "test_1a", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((g2 = H5Gcreate2(g1, "sub_1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((g3 = H5Gcreate2(fid, "test_1b", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gset_comment(g3, ".", "hello world") < 0) TEST_ERROR
if(H5Gclose(g1) < 0) TEST_ERROR
if(H5Gclose(g2) < 0) TEST_ERROR
@@ -131,12 +133,12 @@ test_misc(hid_t fapl, hbool_t new_format)
/* Check that creating groups with no-op names isn't allowed */
H5E_BEGIN_TRY {
- g1 = H5Gcreate(fid, "/", (size_t)0);
+ g1 = H5Gcreate2(fid, "/", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY
if(g1 >= 0) TEST_ERROR
H5E_BEGIN_TRY {
- g1 = H5Gcreate(fid, "./././", (size_t)0);
+ g1 = H5Gcreate2(fid, "./././", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY
if(g1 >= 0) TEST_ERROR
@@ -196,8 +198,8 @@ test_long(hid_t fapl, hbool_t new_format)
sprintf(name2, "%s/%s", name1, name1);
/* Create groups */
- if((g1 = H5Gcreate(fid, name1, (size_t)0)) < 0) TEST_ERROR
- if((g2 = H5Gcreate(g1, name1, (size_t)0)) < 0) TEST_ERROR
+ if((g1 = H5Gcreate2(fid, name1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((g2 = H5Gcreate2(g1, name1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(g1) < 0) TEST_ERROR
if(H5Gclose(g2) < 0) TEST_ERROR
@@ -242,9 +244,6 @@ error:
* robb@maya.nuance.com
* Aug 29 1997
*
- * Modifications:
- * Robb Matzke, 2002-03-28
- * File is opened by parent instead of here.
*-------------------------------------------------------------------------
*/
static int
@@ -269,12 +268,12 @@ test_large(hid_t fapl, hbool_t new_format)
* Create a directory that has so many entries that the root
* of the B-tree ends up splitting.
*/
- if((cwg = H5Gcreate(fid, "/big", (size_t)(LARGE_NOBJS * 16 + 2))) < 0) TEST_ERROR
+ if((cwg = H5Gcreate2(fid, "/big", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(new_format)
if(H5G_has_stab_test(cwg) != FALSE) TEST_ERROR
for(i = 0; i < LARGE_NOBJS; i++) {
sprintf(name, "%05d%05d", (HDrandom() % 100000), i);
- if((dir = H5Gcreate(cwg, name, (size_t)0)) < 0) TEST_ERROR
+ if((dir = H5Gcreate2(cwg, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(dir) < 0) TEST_ERROR
}
if(new_format)
@@ -314,13 +313,12 @@ test_large(hid_t fapl, hbool_t new_format)
*-------------------------------------------------------------------------
*/
static int
-lifecycle(hid_t fapl)
+lifecycle(hid_t fapl2)
{
hid_t fid = (-1); /* File ID */
hid_t gid = (-1); /* Group ID */
hid_t gid2 = (-1); /* Datatype ID */
hid_t gcpl = (-1); /* Group creation property list ID */
- hid_t fapl2 = (-1); /* File access property list ID */
size_t lheap_size_hint; /* Local heap size hint */
unsigned max_compact; /* Maximum # of links to store in group compactly */
unsigned min_dense; /* Minimum # of links to store in group "densely" */
@@ -336,12 +334,6 @@ lifecycle(hid_t fapl)
TESTING("group lifecycle");
- /* Copy the file access property list */
- if((fapl2 = H5Pcopy(fapl)) < 0) TEST_ERROR
-
- /* Set the "use the latest version of the format" flag for creating objects in the file */
- if(H5Pset_latest_format(fapl2, TRUE) < 0) TEST_ERROR
-
/* Create file */
h5_fixname(FILENAME[0], fapl2, filename, sizeof(filename));
if((fid = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl2)) < 0) TEST_ERROR
@@ -391,7 +383,7 @@ lifecycle(hid_t fapl)
/* Create first "bottom" group */
sprintf(objname, LIFECYCLE_BOTTOM_GROUP, (unsigned)0);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -408,7 +400,7 @@ lifecycle(hid_t fapl)
/* (Start counting at '1', since we've already created one bottom group */
for(u = 1; u < LIFECYCLE_MAX_COMPACT; u++) {
sprintf(objname, LIFECYCLE_BOTTOM_GROUP, u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -436,7 +428,7 @@ lifecycle(hid_t fapl)
/* Create one more "bottom" group, which should push top group into using a symbol table */
sprintf(objname, LIFECYCLE_BOTTOM_GROUP, u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -503,9 +495,6 @@ lifecycle(hid_t fapl)
/* Close GCPL */
if(H5Pclose(gcpl) < 0) TEST_ERROR
- /* Close FAPL copy */
- if(H5Pclose(fapl2) < 0) TEST_ERROR
-
/* Close file */
if(H5Fclose(fid) < 0) TEST_ERROR
@@ -521,7 +510,6 @@ lifecycle(hid_t fapl)
error:
H5E_BEGIN_TRY {
- H5Pclose(fapl2);
H5Gclose(gcpl);
H5Gclose(gid2);
H5Gclose(gid);
@@ -547,12 +535,11 @@ error:
*-------------------------------------------------------------------------
*/
static int
-long_compact(hid_t fapl)
+long_compact(hid_t fapl2)
{
hid_t fid = (-1); /* File ID */
hid_t gid = (-1); /* Group ID */
hid_t gid2 = (-1); /* Group ID */
- hid_t fapl2 = (-1); /* File access property list ID */
char *objname; /* Object name */
char filename[NAME_BUF_SIZE];
h5_stat_size_t empty_size; /* Size of an empty file */
@@ -560,12 +547,6 @@ long_compact(hid_t fapl)
TESTING("long link names in compact groups");
- /* Copy the file access property list */
- if((fapl2 = H5Pcopy(fapl)) < 0) TEST_ERROR
-
- /* Set the "use the latest version of the format" flag for creating objects in the file */
- if(H5Pset_latest_format(fapl2, TRUE) < 0) TEST_ERROR
-
/* Create file */
h5_fixname(FILENAME[0], fapl2, filename, sizeof(filename));
if((fid = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl2)) < 0) TEST_ERROR
@@ -585,13 +566,13 @@ long_compact(hid_t fapl)
if((fid = H5Fopen(filename, H5F_ACC_RDWR, fapl2)) < 0) TEST_ERROR
/* Create top group */
- if((gid = H5Gcreate(fid, "top", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, "top", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Use internal testing routine to check that the group has no links or dense storage */
if(H5G_is_empty_test(gid) != TRUE) TEST_ERROR
/* Create first group with "long" name */
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -607,7 +588,7 @@ long_compact(hid_t fapl)
/* Create second group with "long" name */
objname[0] = 'b';
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -647,9 +628,6 @@ long_compact(hid_t fapl)
/* Unlink top group */
if(H5Gunlink(fid, "top") < 0) TEST_ERROR
- /* Close FAPL copy */
- if(H5Pclose(fapl2) < 0) TEST_ERROR
-
/* Close file */
if(H5Fclose(fid) < 0) TEST_ERROR
@@ -664,7 +642,6 @@ long_compact(hid_t fapl)
error:
H5E_BEGIN_TRY {
- H5Pclose(fapl2);
H5Gclose(gid2);
H5Gclose(gid);
H5Fclose(fid);
@@ -688,7 +665,7 @@ error:
*-------------------------------------------------------------------------
*/
static int
-read_old(hid_t fapl)
+read_old(hid_t fapl2)
{
int fd_old = (-1), fd_new = (-1); /* File descriptors for copying data */
hid_t fid = (-1); /* File ID */
@@ -712,7 +689,7 @@ read_old(hid_t fapl)
HDstrcat(filename, FILE_OLD_GROUPS);
/* Create filename */
- h5_fixname(FILENAME[0], fapl, filename2, sizeof(filename2));
+ h5_fixname(FILENAME[0], fapl2, filename2, sizeof(filename2));
/* Copy old file into temporary file */
if((fd_old = HDopen(filename, O_RDONLY, 0666)) < 0) TEST_ERROR
@@ -728,7 +705,7 @@ read_old(hid_t fapl)
/* Open copied file */
- if((fid = H5Fopen(filename2, H5F_ACC_RDWR, fapl)) < 0) TEST_ERROR
+ if((fid = H5Fopen(filename2, H5F_ACC_RDWR, fapl2)) < 0) TEST_ERROR
/* Attempt to open "old" group */
if((gid = H5Gopen(fid, "old")) < 0) TEST_ERROR
@@ -741,7 +718,7 @@ read_old(hid_t fapl)
/* Create a bunch of objects in the group */
for(u = 0; u < READ_OLD_NGROUPS; u++) {
sprintf(objname, "Group %u", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -802,13 +779,12 @@ error:
*-------------------------------------------------------------------------
*/
static int
-no_compact(hid_t fapl)
+no_compact(hid_t fapl2)
{
hid_t fid = (-1); /* File ID */
hid_t gid = (-1); /* Group ID */
hid_t gid2 = (-1); /* Datatype ID */
hid_t gcpl = (-1); /* Group creation property list ID */
- hid_t fapl2 = (-1); /* File access property list ID */
char objname[NAME_BUF_SIZE]; /* Object name */
char filename[NAME_BUF_SIZE];
h5_stat_size_t empty_size; /* Size of an empty file */
@@ -818,12 +794,6 @@ no_compact(hid_t fapl)
TESTING("group without compact form");
- /* Copy the file access property list */
- if((fapl2 = H5Pcopy(fapl)) < 0) TEST_ERROR
-
- /* Set the "use the latest version of the format" flag for creating objects in the file */
- if(H5Pset_latest_format(fapl2, TRUE) < 0) TEST_ERROR
-
/* Create file */
h5_fixname(FILENAME[0], fapl2, filename, sizeof(filename));
if((fid = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl2)) < 0) TEST_ERROR
@@ -859,7 +829,7 @@ no_compact(hid_t fapl)
/* Create first "bottom" group */
sprintf(objname, NO_COMPACT_BOTTOM_GROUP, (unsigned)0);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Check on bottom group's status */
if(H5G_is_empty_test(gid2) != TRUE) TEST_ERROR
@@ -885,9 +855,6 @@ no_compact(hid_t fapl)
/* Unlink top group */
if(H5Gunlink(fid, NO_COMPACT_TOP_GROUP) < 0) TEST_ERROR
- /* Close FAPL copy */
- if(H5Pclose(fapl2) < 0) TEST_ERROR
-
/* Close file */
if(H5Fclose(fid) < 0) TEST_ERROR
@@ -903,7 +870,6 @@ no_compact(hid_t fapl)
error:
H5E_BEGIN_TRY {
- H5Pclose(fapl2);
H5Gclose(gcpl);
H5Gclose(gid2);
H5Gclose(gid);
@@ -928,13 +894,12 @@ error:
*-------------------------------------------------------------------------
*/
static int
-gcpl_on_root(hid_t fapl)
+gcpl_on_root(hid_t fapl2)
{
hid_t fid = (-1); /* File ID */
hid_t gid = (-1); /* Group ID */
hid_t gid2 = (-1); /* Datatype ID */
hid_t fcpl = (-1); /* File creation property list ID */
- hid_t fapl2 = (-1); /* File access property list ID */
hid_t gcpl = (-1); /* Group creation property list ID */
hid_t lcpl = (-1); /* Link creation property list ID */
unsigned max_compact; /* Maximum # of links to store in group compactly */
@@ -943,12 +908,6 @@ gcpl_on_root(hid_t fapl)
TESTING("setting root group creation properties");
- /* Copy the file access property list */
- if((fapl2 = H5Pcopy(fapl)) < 0) TEST_ERROR
-
- /* Set the "use the latest version of the format" flag for creating objects in the file */
- if(H5Pset_latest_format(fapl2, TRUE) < 0) TEST_ERROR
-
/* Create file */
h5_fixname(FILENAME[0], fapl2, filename, sizeof(filename));
@@ -1021,9 +980,6 @@ gcpl_on_root(hid_t fapl)
/* Close root group */
if(H5Gclose(gid) < 0) TEST_ERROR
- /* Close FAPL copy */
- if(H5Pclose(fapl2) < 0) TEST_ERROR
-
/* Close file */
if(H5Fclose(fid) < 0) TEST_ERROR
@@ -1037,7 +993,6 @@ error:
H5Gclose(gcpl);
H5Gclose(gid2);
H5Gclose(gid);
- H5Pclose(fapl2);
H5Gclose(fcpl);
H5Fclose(fid);
} H5E_END_TRY;
@@ -1046,6 +1001,91 @@ error:
/*-------------------------------------------------------------------------
+ * Function: old_api
+ *
+ * Purpose: Test old API routines
+ *
+ * Return: Success: 0
+ * Failure: -1
+ *
+ * Programmer: Quincey Koziol
+ * Thursday, August 23, 2007
+ *
+ *-------------------------------------------------------------------------
+ */
+static int
+old_api(hid_t fapl)
+{
+#ifndef H5_NO_DEPRECATED_SYMBOLS
+ hid_t fid = (-1); /* File ID */
+ hid_t gid = (-1); /* Group ID */
+ h5_stat_size_t small_file_size; /* Size of small group file */
+ h5_stat_size_t large_file_size; /* Size of large group file */
+ char filename[NAME_BUF_SIZE];
+#endif /* H5_NO_DEPRECATED_SYMBOLS */
+
+ TESTING("old API routines");
+
+#ifndef H5_NO_DEPRECATED_SYMBOLS
+ /* Create file */
+ h5_fixname(FILENAME[0], fapl, filename, sizeof(filename));
+
+ /* Create file */
+ if((fid = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+
+ /* Create a group, with the old API routine and a "small" heap */
+ if((gid = H5Gcreate1(fid, OLD_API_GROUP, (size_t)0)) < 0) FAIL_STACK_ERROR
+
+ /* Close group */
+ if(H5Gclose(gid) < 0) FAIL_STACK_ERROR
+
+ /* Close file */
+ if(H5Fclose(fid) < 0) FAIL_STACK_ERROR
+
+ /* Get the size of the file with a "small" heap for group */
+ if((small_file_size = h5_get_file_size(filename)) < 0) TEST_ERROR
+
+ /* Create file */
+ if((fid = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) FAIL_STACK_ERROR
+
+ /* Create a group, with the old API routine and a "large" heap */
+ if((gid = H5Gcreate1(fid, OLD_API_GROUP, (size_t)10000)) < 0) FAIL_STACK_ERROR
+
+ /* Close group */
+ if(H5Gclose(gid) < 0) FAIL_STACK_ERROR
+
+ /* Close file */
+ if(H5Fclose(fid) < 0) FAIL_STACK_ERROR
+
+ /* Get the size of the file with a "large" heap for group */
+ if((large_file_size = h5_get_file_size(filename)) < 0) TEST_ERROR
+
+ /* Check that the file with a "large" group heap is actually bigger */
+ if(large_file_size <= small_file_size) TEST_ERROR
+
+ PASSED();
+#else /* H5_NO_DEPRECATED_SYMBOLS */
+ /* Shut compiler up */
+ fapl = fapl;
+
+ SKIPPED();
+ puts(" Deprecated API symbols not enabled");
+#endif /* H5_NO_DEPRECATED_SYMBOLS */
+
+ return 0;
+
+#ifndef H5_NO_DEPRECATED_SYMBOLS
+error:
+ H5E_BEGIN_TRY {
+ H5Gclose(gid);
+ H5Fclose(fid);
+ } H5E_END_TRY;
+ return 1;
+#endif /* H5_NO_DEPRECATED_SYMBOLS */
+} /* end old_api() */
+
+
+/*-------------------------------------------------------------------------
* Function: main
*
* Purpose: Test groups
@@ -1072,6 +1112,7 @@ main(void)
envval = "nomatch";
if(HDstrcmp(envval, "split") && HDstrcmp(envval, "multi") && HDstrcmp(envval, "family")) {
hid_t fapl, fapl2; /* File access property list IDs */
+ hbool_t new_format; /* Whether to use the new format or not */
int nerrors = 0;
/* Reset library */
@@ -1084,20 +1125,23 @@ main(void)
/* Set the "use the latest version of the format" flag for creating objects in the file */
if(H5Pset_latest_format(fapl2, TRUE) < 0) TEST_ERROR
- /* Perform basic tests, with old & new style groups */
- nerrors += test_misc(fapl, FALSE); /* with old-style group */
- nerrors += test_misc(fapl2, TRUE); /* with new-style group */
- nerrors += test_long(fapl, FALSE); /* with old-style group */
- nerrors += test_long(fapl2, TRUE); /* with new-style group */
- nerrors += test_large(fapl, FALSE); /* with old-style group */
- nerrors += test_large(fapl2, TRUE); /* with new-style group */
+ /* Loop over using new group format */
+ for(new_format = FALSE; new_format <= TRUE; new_format++) {
+ /* Perform basic tests, with old & new style groups */
+ nerrors += test_misc((new_format ? fapl2 : fapl), new_format);
+ nerrors += test_long((new_format ? fapl2 : fapl), new_format);
+ nerrors += test_large((new_format ? fapl2 : fapl), new_format);
+ } /* end for */
/* New format group specific tests (require new format features) */
- nerrors += lifecycle(fapl);
- nerrors += long_compact(fapl);
- nerrors += read_old(fapl);
- nerrors += no_compact(fapl);
- nerrors += gcpl_on_root(fapl);
+ nerrors += lifecycle(fapl2);
+ nerrors += long_compact(fapl2);
+ nerrors += read_old(fapl2);
+ nerrors += no_compact(fapl2);
+ nerrors += gcpl_on_root(fapl2);
+
+ /* Old group API specific tests */
+ nerrors += old_api(fapl);
/* Close 2nd FAPL */
H5Pclose(fapl2);
diff --git a/test/tattr.c b/test/tattr.c
index 55b3f01..969a0d9 100644
--- a/test/tattr.c
+++ b/test/tattr.c
@@ -334,8 +334,8 @@ test_attr_basic_write(hid_t fapl)
CHECK(ret, FAIL, "H5Dclose");
/* Create group */
- group = H5Gcreate(fid1, GROUP1_NAME, (size_t)0);
- CHECK(group, FAIL, "H5Gcreate");
+ group = H5Gcreate2(fid1, GROUP1_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group, FAIL, "H5Gcreate2");
/* Create dataspace for attribute */
sid2 = H5Screate_simple(ATTR2_RANK, dims3, NULL);
@@ -8099,8 +8099,8 @@ test_attr_bug1(hid_t fcpl, hid_t fapl)
fid = H5Fcreate(FILENAME, H5F_ACC_TRUNC, fcpl, fapl);
CHECK(fid, FAIL, "H5Fcreate");
- gid = H5Gcreate(fid, GROUP1_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, GROUP1_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
ret = H5Gclose(gid);
CHECK(ret, FAIL, "H5Gclose");
@@ -8114,8 +8114,8 @@ test_attr_bug1(hid_t fcpl, hid_t fapl)
CHECK(fid, FAIL, "H5Fopen");
/* Create second group */
- gid = H5Gcreate(fid, GROUP2_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, GROUP2_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
ret = H5Gclose(gid);
CHECK(ret, FAIL, "H5Gclose");
@@ -8143,8 +8143,8 @@ test_attr_bug1(hid_t fcpl, hid_t fapl)
CHECK(fid, FAIL, "H5Fopen");
/* Create third group */
- gid = H5Gcreate(fid, GROUP3_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, GROUP3_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
ret = H5Gclose(gid);
CHECK(ret, FAIL, "H5Gclose");
diff --git a/test/testmeta.c b/test/testmeta.c
index 034233c..db97b28 100644
--- a/test/testmeta.c
+++ b/test/testmeta.c
@@ -18,10 +18,10 @@
* to HDF5 1.4.1-post2 or 1.4.2-pre3 debug library.
*
* If the assertion errors are ignored, the program eventially causes
- * an error in H5Gcreate when writing object 83381.
+ * an error in H5Gcreate2 when writing object 83381.
*
* When writing in single file mode, the assertion errors still occur
- * but the H5Gcreate error does not.
+ * but the H5Gcreate2 error does not.
*/
@@ -102,7 +102,7 @@ int main(void)
status = H5Pclose(prop_id);
/* Create group to hold data object data arrays */
- group_id = H5Gcreate(file_id, "/DataArray", 0);
+ group_id = H5Gcreate2(file_id, "/DataArray", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
H5Gclose(group_id);
for(j=0; j<NDATAOBJECTS; j++)
@@ -114,9 +114,8 @@ int main(void)
/* Create group to hold data arrays for this object */
sprintf(name, "/DataArray/%06d", j);
- group_id = H5Gcreate(file_id, name, 0);
- if(group_id < 0)
- {
+ group_id = H5Gcreate2(file_id, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ if(group_id < 0) {
fprintf(stderr, "Failed to create DataArray group.\n");
status = H5Fclose(file_id);
return -1;
@@ -240,3 +239,4 @@ int main(void)
return 0;
}
+
diff --git a/test/tfile.c b/test/tfile.c
index 91cfa58..882061f 100644
--- a/test/tfile.c
+++ b/test/tfile.c
@@ -828,8 +828,8 @@ create_objects(hid_t fid1, hid_t fid2, hid_t *ret_did, hid_t *ret_gid1,
/* Create a group in the second file open */
{
hid_t gid1, gid2, gid3;
- gid1 = H5Gcreate(fid2, "/group", (size_t)0);
- CHECK(gid1, FAIL, "H5Gcreate");
+ gid1 = H5Gcreate2(fid2, "/group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid1, FAIL, "H5Gcreate2");
if(ret_gid1 != NULL)
*ret_gid1 = gid1;
@@ -897,8 +897,8 @@ test_get_file_id(void)
/* Create a group in the file. Make a duplicated file ID from the group.
* And close this duplicated ID
*/
- group_id = H5Gcreate(fid, GRP_NAME, (size_t)0);
- CHECK(group_id, FAIL, "H5Gcreate");
+ group_id = H5Gcreate2(fid, GRP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group_id, FAIL, "H5Gcreate2");
/* Test H5Iget_file_id() */
check_file_id(fid, group_id);
@@ -918,7 +918,7 @@ test_get_file_id(void)
CHECK(fid, FAIL, "H5Fcreate");
group_id = H5Gopen(fid, GRP_NAME);
- CHECK(group_id, FAIL, "H5Gcreate");
+ CHECK(group_id, FAIL, "H5Gopen");
/* Test H5Iget_file_id() */
check_file_id(fid, group_id);
@@ -1374,8 +1374,8 @@ test_file_open_dot(void)
CHECK(fid, FAIL, "H5Fcreate");
/* Create a group in the HDF5 file */
- gid = H5Gcreate(fid, GRP_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, GRP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Create a dataspace for creating datasets */
sid = H5Screate(H5S_SCALAR);
@@ -1435,15 +1435,15 @@ test_file_open_dot(void)
/* Create a group with no name using the file ID */
H5E_BEGIN_TRY {
- gid2 = H5Gcreate(fid, ".", (size_t)0);
+ gid2 = H5Gcreate2(fid, ".", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
- VERIFY(gid2, FAIL, "H5Gcreate");
+ VERIFY(gid2, FAIL, "H5Gcreate2");
/* Create a group with no name using the group ID */
H5E_BEGIN_TRY {
- gid2 = H5Gcreate(gid, ".", (size_t)0);
+ gid2 = H5Gcreate2(gid, ".", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
- VERIFY(gid2, FAIL, "H5Gcreate");
+ VERIFY(gid2, FAIL, "H5Gcreate2");
/* Open a group with no name using the file ID (should open the root group) */
gid2 = H5Gopen(fid, ".");
@@ -1507,8 +1507,8 @@ test_file_open_overlap(void)
VERIFY(intent, H5F_ACC_RDWR, "H5Fget_intent");
/* Create a group in file */
- gid = H5Gcreate(fid1, GROUP1, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid1, GROUP1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Create dataspace for dataset */
sid = H5Screate(H5S_SCALAR);
@@ -1595,8 +1595,8 @@ test_file_getname(void)
VERIFY_STR(name, FILE1, "H5Fget_name");
/* Create a group in the root group */
- group_id = H5Gcreate(file_id, TESTA_GROUPNAME, (size_t)0);
- CHECK(group_id, FAIL, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, TESTA_GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group_id, FAIL, "H5Gcreate2");
/* Get and verify file name */
name_len = H5Fget_name(group_id, name, (size_t)TESTA_NAME_BUF_SIZE);
@@ -1734,8 +1734,8 @@ test_file_double_group_open(void)
file2_id = H5Fopen (FILE1, H5F_ACC_RDONLY, H5P_DEFAULT);
CHECK(file2_id, FAIL, "H5Fopen");
- grp1_id = H5Gcreate(file1_id, GRP_NAME, (size_t)0);
- CHECK(grp1_id, FAIL, "H5Gcreate");
+ grp1_id = H5Gcreate2(file1_id, GRP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp1_id, FAIL, "H5Gcreate2");
grp2_id = H5Gopen(file2_id, GRP_NAME);
CHECK(grp2_id, FAIL, "H5Gopen");
diff --git a/test/th5o.c b/test/th5o.c
index 09ba28f..e83b920 100644
--- a/test/th5o.c
+++ b/test/th5o.c
@@ -57,8 +57,8 @@ test_h5o_open(void)
/* Create a group, dataset, and committed datatype within the file */
/* Create the group */
- grp = H5Gcreate(fid, "group", (size_t)0);
- CHECK(grp, FAIL, "H5Gcreate");
+ grp = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp, FAIL, "H5Gcreate2");
ret = H5Gclose(grp);
CHECK(ret, FAIL, "H5Gclose");
@@ -162,8 +162,8 @@ test_h5o_close(void)
/* Create a group, dataset, and committed datatype within the file */
/* Create the group and close it with H5Oclose */
- grp = H5Gcreate(fid, "group", (size_t)0);
- CHECK(grp, FAIL, "H5Gcreate");
+ grp = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp, FAIL, "H5Gcreate2");
VERIFY(H5Iget_type(grp), H5I_GROUP, "H5Iget_type");
ret = H5Oclose(grp);
CHECK(ret, FAIL, "H5Oclose");
@@ -259,8 +259,8 @@ test_h5o_open_by_addr(void)
/* Create a group, dataset, and committed datatype within the file */
/* Create the group */
- grp = H5Gcreate(fid, "group", (size_t)0);
- CHECK(grp, FAIL, "H5Gcreate");
+ grp = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp, FAIL, "H5Gcreate2");
ret = H5Gclose(grp);
CHECK(ret, FAIL, "H5Gclose");
@@ -388,8 +388,8 @@ test_h5o_refcount(void)
/* Create a group, dataset, and committed datatype within the file */
/* Create the group */
- grp = H5Gcreate(fid, "group", (size_t)0);
- CHECK(grp, FAIL, "H5Gcreate");
+ grp = H5Gcreate2(fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp, FAIL, "H5Gcreate2");
/* Commit the type inside the group */
dtype = H5Tcopy(H5T_NATIVE_INT);
diff --git a/test/titerate.c b/test/titerate.c
index e60d98a..5fc568f 100644
--- a/test/titerate.c
+++ b/test/titerate.c
@@ -165,8 +165,8 @@ static void test_iter_group(hid_t fapl, hbool_t new_format)
/* Create a group and named datatype under root group for testing
* H5Gget_objtype_by_idx.
*/
- grp = H5Gcreate(file, "grp", (size_t)0);
- CHECK(ret, FAIL, "H5Gcreate");
+ grp = H5Gcreate2(file, "grp", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(ret, FAIL, "H5Gcreate2");
lnames[NDATASETS] = HDstrdup("grp");
CHECK(lnames[NDATASETS], NULL, "strdup");
@@ -611,8 +611,8 @@ static void test_iter_group_large(hid_t fapl)
names[i].type = H5G_GROUP;
/* Create a group */
- group = H5Gcreate(file, gname, (size_t)0);
- CHECK(group, FAIL, "H5Gcreate");
+ group = H5Gcreate2(file, gname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group, FAIL, "H5Gcreate2");
/* Close a group */
ret = H5Gclose(group);
@@ -730,8 +730,8 @@ static void test_grp_memb_funcs(hid_t fapl)
/* Create a group and named datatype under root group for testing
* H5Gget_objtype_by_idx.
*/
- grp = H5Gcreate(file, "grp", (size_t)0);
- CHECK(ret, FAIL, "H5Gcreate");
+ grp = H5Gcreate2(file, "grp", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(ret, FAIL, "H5Gcreate2");
dnames[NDATASETS] = HDstrdup("grp");
CHECK(dnames[NDATASETS], NULL, "strdup");
@@ -852,11 +852,11 @@ static void test_links(hid_t fapl)
CHECK(file, FAIL, "H5Fcreate");
/* create groups */
- gid = H5Gcreate(file, "/g1", (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(file, "/g1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
- gid1 = H5Gcreate(file, "/g1/g1.1", (size_t)0);
- CHECK(gid1, FAIL, "H5Gcreate");
+ gid1 = H5Gcreate2(file, "/g1/g1.1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid1, FAIL, "H5Gcreate2");
/* create soft and hard links to the group "/g1". */
ret = H5Glink (gid, H5L_TYPE_SOFT, "something", "softlink");
diff --git a/test/tmisc.c b/test/tmisc.c
index 1803087..58cad14 100644
--- a/test/tmisc.c
+++ b/test/tmisc.c
@@ -628,19 +628,19 @@ test_misc4(void)
CHECK(file1, FAIL, "H5Fcreate");
/* Create the first group */
- group1 = H5Gcreate(file1, MISC4_GROUP_1, (size_t)0);
- CHECK(group1, FAIL, "H5Gcreate");
+ group1 = H5Gcreate2(file1, MISC4_GROUP_1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group1, FAIL, "H5Gcreate2");
/* Create the second group */
- group2 = H5Gcreate(file1, MISC4_GROUP_2, (size_t)0);
- CHECK(group2, FAIL, "H5Gcreate");
+ group2 = H5Gcreate2(file1, MISC4_GROUP_2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group2, FAIL, "H5Gcreate2");
file2 = H5Fcreate(MISC4_FILE_2, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
CHECK(file2, FAIL, "H5Fcreate");
/* Create the first group */
- group3 = H5Gcreate(file2, MISC4_GROUP_1, (size_t)0);
- CHECK(group3, FAIL, "H5Gcreate");
+ group3 = H5Gcreate2(file2, MISC4_GROUP_1, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group3, FAIL, "H5Gcreate2");
/* Get the stat information for each group */
ret = H5Gget_objinfo(file1,MISC4_GROUP_1,0,&stat1);
@@ -2181,12 +2181,12 @@ create_hdf_file(const char *name)
CHECK(ret, FAIL, "H5Tclose");
/* Create a group in the root group */
- gid = H5Gcreate(fid, MISC13_GROUP1_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, MISC13_GROUP1_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Create another group in the new group */
- gid2 = H5Gcreate(gid, MISC13_GROUP2_NAME, (size_t)0);
- CHECK(gid2, FAIL, "H5Gcreate");
+ gid2 = H5Gcreate2(gid, MISC13_GROUP2_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid2, FAIL, "H5Gcreate2");
/* Close the second group */
ret = H5Gclose(gid2);
@@ -3255,8 +3255,8 @@ test_misc19(void)
CHECK(fid, FAIL, "H5Fcreate");
/* Create a group */
- gid = H5Gcreate(fid, MISC19_GROUP_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, MISC19_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Check the reference count */
rc = H5Iget_ref(gid);
@@ -3813,8 +3813,8 @@ test_misc23(void)
/* Build some infrastructure */
- group_id = H5Gcreate(file_id, "/A", (size_t)0);
- CHECK(group_id, FAIL, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, "/A", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group_id, FAIL, "H5Gcreate2");
space_id = H5Screate_simple(1, dims, NULL);
CHECK(space_id, FAIL, "H5Screate_simple");
@@ -3828,13 +3828,13 @@ test_misc23(void)
**********************************************************************/
H5E_BEGIN_TRY {
- tmp_id = H5Gcreate(file_id, "/A/B00a/grp", (size_t)0);
+ tmp_id = H5Gcreate2(file_id, "/A/B00a/grp", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
- VERIFY(tmp_id, FAIL, "H5Gcreate");
+ VERIFY(tmp_id, FAIL, "H5Gcreate2");
- tmp_id = H5Gcreate(file_id, "/A/grp", (size_t)0);
- CHECK(tmp_id, FAIL, "H5Gcreate");
+ tmp_id = H5Gcreate2(file_id, "/A/grp", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(tmp_id, FAIL, "H5Gcreate2");
status = H5Gclose(tmp_id);
CHECK(status, FAIL, "H5Gclose");
@@ -4075,8 +4075,8 @@ test_misc24(void)
CHECK(space_id, FAIL, "H5Screate");
/* Create group, dataset & named datatype objects */
- group_id = H5Gcreate(file_id, MISC24_GROUP_NAME, (size_t)0);
- CHECK(group_id, FAIL, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, MISC24_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group_id, FAIL, "H5Gcreate2");
dset_id = H5Dcreate(file_id, MISC24_DATASET_NAME, H5T_NATIVE_INT, space_id, H5P_DEFAULT);
CHECK(dset_id, FAIL, "H5Dcreate");
@@ -4282,24 +4282,24 @@ test_misc25a(void)
CHECK(fid, FAIL, "H5Fcreate");
/* Create top group */
- gid = H5Gcreate(fid, MISC25A_GROUP0_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, MISC25A_GROUP0_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Close top group */
ret = H5Gclose(gid);
CHECK(ret, FAIL, "H5Gclose");
/* Create first group */
- gid = H5Gcreate(fid, MISC25A_GROUP1_NAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, MISC25A_GROUP1_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Close first group */
ret = H5Gclose(gid);
CHECK(ret, FAIL, "H5Gclose");
/* Create second group */
- gid2 = H5Gcreate(fid, MISC25A_GROUP2_NAME, (size_t)0);
- CHECK(gid2, FAIL, "H5Gcreate");
+ gid2 = H5Gcreate2(fid, MISC25A_GROUP2_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid2, FAIL, "H5Gcreate2");
/* Close second group */
ret = H5Gclose(gid2);
@@ -4384,8 +4384,8 @@ test_misc25a(void)
CHECK(fid, FAIL, "H5Fopen");
/* Create third group */
- gid3 = H5Gcreate(fid, MISC25A_GROUP3_NAME, (size_t)0);
- CHECK(gid3, FAIL, "H5Gcreate");
+ gid3 = H5Gcreate2(fid, MISC25A_GROUP3_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid3, FAIL, "H5Gcreate2");
/* Close third group */
ret = H5Gclose(gid3);
@@ -4651,7 +4651,7 @@ test_misc25c(void)
/* Create a group for the dataset */
gid = H5Gcreate2(fid, MISC25C_DSETGRPNAME, H5P_DEFAULT, gcpl, H5P_DEFAULT);
- CHECK(gid, FAIL, "H5Gcreate");
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Create the dataspace */
sid = H5Screate(H5S_SCALAR);
@@ -4662,8 +4662,8 @@ test_misc25c(void)
CHECK(did, FAIL, "H5Dcreate");
/* Create an extra group */
- gid2 = H5Gcreate(fid, MISC25C_GRPNAME, (size_t)0);
- CHECK(gid2, FAIL, "H5Gcreate");
+ gid2 = H5Gcreate2(fid, MISC25C_GRPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid2, FAIL, "H5Gcreate2");
/* Close the extra group */
ret = H5Gclose(gid2);
@@ -4678,8 +4678,8 @@ test_misc25c(void)
CHECK(ret, FAIL, "H5Aclose");
/* Create a second extra group */
- gid2 = H5Gcreate(fid, MISC25C_GRPNAME2, (size_t)0);
- CHECK(gid2, FAIL, "H5Gcreate");
+ gid2 = H5Gcreate2(fid, MISC25C_GRPNAME2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid2, FAIL, "H5Gcreate2");
/* Close the second extra group */
ret = H5Gclose(gid2);
diff --git a/test/trefer.c b/test/trefer.c
index 924d72c..6f984f3 100644
--- a/test/trefer.c
+++ b/test/trefer.c
@@ -106,8 +106,8 @@ test_reference_obj(void)
CHECK(sid1, FAIL, "H5Screate_simple");
/* Create a group */
- group=H5Gcreate(fid1,"Group1",(size_t)-1);
- CHECK(group, FAIL, "H5Gcreate");
+ group = H5Gcreate2(fid1, "Group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group, FAIL, "H5Gcreate2");
/* Set group's comment */
ret=H5Gset_comment(group,".",write_comment);
@@ -999,17 +999,17 @@ test_reference_group(void)
CHECK(sid, FAIL, "H5Screate");
/* Create group to refer to */
- gid = H5Gcreate(fid, GROUPNAME, (size_t)0);
- CHECK(gid, FAIL, "H5Gcreate");
+ gid = H5Gcreate2(fid, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid, FAIL, "H5Gcreate2");
/* Create nested groups */
- gid2 = H5Gcreate(gid, GROUPNAME2, (size_t)0);
- CHECK(gid2, FAIL, "H5Gcreate");
+ gid2 = H5Gcreate2(gid, GROUPNAME2, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid2, FAIL, "H5Gcreate2");
ret = H5Gclose(gid2);
CHECK(ret, FAIL, "H5Gclose");
- gid2 = H5Gcreate(gid, GROUPNAME3, (size_t)0);
- CHECK(gid2, FAIL, "H5Gcreate");
+ gid2 = H5Gcreate2(gid, GROUPNAME3, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(gid2, FAIL, "H5Gcreate2");
ret = H5Gclose(gid2);
CHECK(ret, FAIL, "H5Gclose");
diff --git a/test/tsohm.c b/test/tsohm.c
index 934c256..7948443 100644
--- a/test/tsohm.c
+++ b/test/tsohm.c
@@ -996,8 +996,8 @@ static void sohm_attr_helper(hid_t fcpl_id)
CHECK_I(space_id, "H5Screate_simple");
/* Create and verify an attribute on a group */
- group_id = H5Gcreate(file_id, "group", 100);
- CHECK_I(group_id, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK_I(group_id, "H5Gcreate2");
attr_id = H5Acreate(group_id, "attribute", type_id, space_id, H5P_DEFAULT);
CHECK_I(attr_id, "H5Acreate");
ret = H5Awrite(attr_id, H5T_NATIVE_INT, wdata);
@@ -1032,8 +1032,8 @@ static void sohm_attr_helper(hid_t fcpl_id)
CHECK_I(ret, "H5Tcommit");
/* Create and verify an attribute */
- group_id = H5Gcreate(file_id, "another_group", 100);
- CHECK_I(group_id, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, "another_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK_I(group_id, "H5Gcreate2");
attr_id = H5Acreate(group_id, "attribute", type_id, space_id, H5P_DEFAULT);
CHECK_I(attr_id, "H5Acreate");
ret = H5Awrite(attr_id, H5T_NATIVE_INT, wdata);
@@ -1524,8 +1524,8 @@ size2_helper(hid_t fcpl_id, int test_file_closing, size2_helper_struct *ret_size
/* Now create a new group filled with datasets that use all different messages */
file_id = H5Fopen(FILENAME, H5F_ACC_RDWR, H5P_DEFAULT);
CHECK_I(file_id, "H5Fopen");
- group_id = H5Gcreate(file_id, "group", 0);
- CHECK_I(group_id, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK_I(group_id, "H5Gcreate2");
/* Create NUM_DATASETS datasets in the new group */
for(x=0; x<NUM_DATASETS; ++x)
@@ -1565,8 +1565,8 @@ size2_helper(hid_t fcpl_id, int test_file_closing, size2_helper_struct *ret_size
/* Create a new group and interleave writes of datasets types 1 and 2. */
file_id = H5Fopen(FILENAME, H5F_ACC_RDWR, H5P_DEFAULT);
CHECK_I(file_id, "H5Fopen");
- group_id = H5Gcreate(file_id, "interleaved group", 0);
- CHECK_I(group_id, "H5Gcreate");
+ group_id = H5Gcreate2(file_id, "interleaved group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK_I(group_id, "H5Gcreate2");
/* Create NUM_DATASETS datasets in the new group */
for(x=0; x<NUM_DATASETS; x+=2)
diff --git a/test/tunicode.c b/test/tunicode.c
index 67cdd61..7135272 100644
--- a/test/tunicode.c
+++ b/test/tunicode.c
@@ -391,8 +391,8 @@ void test_objnames(hid_t fid, const char* string)
herr_t ret;
/* Create a group with a UTF-8 name */
- grp_id = H5Gcreate(fid, string, (size_t)0);
- CHECK(grp_id, FAIL, "H5Gcreate");
+ grp_id = H5Gcreate2(fid, string, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp_id, FAIL, "H5Gcreate2");
/* Set a comment on the group to test that we can access the group
* Also test that UTF-8 comments can be read.
@@ -408,8 +408,8 @@ void test_objnames(hid_t fid, const char* string)
VERIFY(strcmp(string, read_buf), 0, "strcmp");
/* Create a new dataset with a UTF-8 name */
- grp1_id = H5Gcreate(fid, GROUP1_NAME, (size_t)0);
- CHECK(grp1_id, FAIL, "H5Gcreate");
+ grp1_id = H5Gcreate2(fid, GROUP1_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp1_id, FAIL, "H5Gcreate2");
space_id = H5Screate_simple(RANK, &dims, NULL);
CHECK(space_id, FAIL, "H5Screate_simple");
@@ -430,8 +430,8 @@ void test_objnames(hid_t fid, const char* string)
CHECK(ret, FAIL, "H5Gclose");
/* Do the same for a named datatype */
- grp2_id = H5Gcreate(fid, GROUP2_NAME, (size_t)0);
- CHECK(grp2_id, FAIL, "H5Gcreate");
+ grp2_id = H5Gcreate2(fid, GROUP2_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp2_id, FAIL, "H5Gcreate2");
type_id = H5Tcreate(H5T_OPAQUE, (size_t)1);
CHECK(type_id, FAIL, "H5Tcreate");
@@ -483,8 +483,8 @@ void test_objnames(hid_t fid, const char* string)
* pointing through the hard link to the datatype. Give the soft
* link a name in UTF-8. Ensure that the soft link works. */
- grp3_id = H5Gcreate(fid, GROUP3_NAME, (size_t)0);
- CHECK(grp3_id, FAIL, "H5Gcreate");
+ grp3_id = H5Gcreate2(fid, GROUP3_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(grp3_id, FAIL, "H5Gcreate2");
ret = H5Glink2(fid, GROUP2_NAME, H5G_LINK_HARD, grp3_id, GROUP2_NAME);
CHECK(ret, FAIL, "H5Glink2");
@@ -519,8 +519,8 @@ void test_attrname(hid_t fid, const char * string)
/* Create a new group and give it an attribute whose
* name and value are UTF-8 strings.
*/
- group_id = H5Gcreate(fid, GROUP4_NAME, (size_t)0);
- CHECK(group_id, FAIL, "H5Gcreate");
+ group_id = H5Gcreate2(fid, GROUP4_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ CHECK(group_id, FAIL, "H5Gcreate2");
space_id = H5Screate_simple(RANK, &dims, NULL);
CHECK(space_id, FAIL, "H5Screate_simple");
diff --git a/test/tvltypes.c b/test/tvltypes.c
index b86bc9c..12c523c 100644
--- a/test/tvltypes.c
+++ b/test/tvltypes.c
@@ -2602,6 +2602,10 @@ test_vltypes_fill_value(void)
#endif /* H5_HAVE_FILTER_DEFLATE */
}
break;
+
+ default:
+ assert(0 && "Unknown layout type!");
+ break;
} /* end switch */
/* Create first data set with default setting - no space is allocated */
@@ -2699,6 +2703,10 @@ test_vltypes_fill_value(void)
dset_select_dspace_id = large_select_dspace_id;
dset_elmts = SPACE4_DIM_LARGE;
break;
+
+ default:
+ assert(0 && "Unknown layout type!");
+ break;
} /* end switch */
/* Open first data set */
@@ -2890,6 +2898,10 @@ test_vltypes_fill_value(void)
dset_select_dspace_id = large_select_dspace_id;
dset_elmts = SPACE4_DIM_LARGE;
break;
+
+ default:
+ assert(0 && "Unknown layout type!");
+ break;
} /* end switch */
/* Copy the dataset's dataspace */
diff --git a/test/unlink.c b/test/unlink.c
index 27401ed..9a515b3 100644
--- a/test/unlink.c
+++ b/test/unlink.c
@@ -107,25 +107,25 @@ test_one(hid_t file)
herr_t status;
/* Create a test group */
- if((work=H5Gcreate(file, "/test_one", (size_t)0)) < 0) goto error;
+ if((work = H5Gcreate2(file, "/test_one", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
/* Delete by absolute name */
TESTING("unlink by absolute name");
- if((grp=H5Gcreate(work, "foo", (size_t)0)) < 0) TEST_ERROR
+ if((grp = H5Gcreate2(work, "foo", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(grp) < 0) TEST_ERROR
if(H5Gunlink(file, "/test_one/foo") < 0) TEST_ERROR
PASSED();
/* Delete by local name */
TESTING("unlink by local name");
- if((grp=H5Gcreate(work, "foo", (size_t)0)) < 0) TEST_ERROR
+ if((grp = H5Gcreate2(work, "foo", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(grp) < 0) TEST_ERROR
if(H5Gunlink(work, "foo") < 0) TEST_ERROR
PASSED();
/* Delete directly - should fail */
TESTING("unlink without a name");
- if((grp=H5Gcreate(work, "foo", (size_t)0)) < 0) TEST_ERROR
+ if((grp = H5Gcreate2(work, "foo", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
H5E_BEGIN_TRY {
status = H5Gunlink(grp, ".");
} H5E_END_TRY;
@@ -172,8 +172,8 @@ test_many(hid_t file)
char name[32];
/* Create a test group */
- if((work=H5Gcreate(file, "/test_many", (size_t)0)) < 0) goto error;
- if((grp = H5Gcreate(work, "/test_many_foo", (size_t)0)) < 0) goto error;
+ if((work = H5Gcreate2(file, "/test_many", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
+ if((grp = H5Gcreate2(work, "/test_many_foo", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) goto error;
if(H5Gclose(grp) < 0) goto error;
/* Create a bunch of names and unlink them in order */
@@ -268,9 +268,9 @@ test_symlink(hid_t file)
TESTING("symlink removal");
/* Create a test group and symlink */
- if ((work=H5Gcreate(file, "/test_symlink", (size_t)0)) < 0) TEST_ERROR
- if (H5Glink(work, H5L_TYPE_SOFT, "link_value", "link") < 0) TEST_ERROR
- if (H5Gunlink(work, "link") < 0) TEST_ERROR
+ if((work = H5Gcreate2(file, "/test_symlink", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if(H5Glink(work, H5L_TYPE_SOFT, "link_value", "link") < 0) TEST_ERROR
+ if(H5Gunlink(work, "link") < 0) TEST_ERROR
/* Cleanup */
if (H5Gclose(work) < 0) TEST_ERROR
@@ -308,14 +308,14 @@ test_rename(hid_t file)
/* Create a test group and rename something */
TESTING("object renaming");
- if ((work=H5Gcreate(file, "/test_rename", (size_t)0)) < 0) TEST_ERROR
- if ((foo=H5Gcreate(work, "foo", (size_t)0)) < 0) TEST_ERROR
- if (H5Gmove(work, "foo", "bar") < 0) TEST_ERROR
- if ((inner=H5Gcreate(foo, "inner", (size_t)0)) < 0) TEST_ERROR
- if (H5Gclose(inner) < 0) TEST_ERROR
- if (H5Gclose(foo) < 0) TEST_ERROR
- if ((inner=H5Gopen(work, "bar/inner")) < 0) TEST_ERROR
- if (H5Gclose(inner) < 0) TEST_ERROR
+ if((work = H5Gcreate2(file, "/test_rename", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((foo = H5Gcreate2(work, "foo", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if(H5Gmove(work, "foo", "bar") < 0) TEST_ERROR
+ if((inner = H5Gcreate2(foo, "inner", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if(H5Gclose(inner) < 0) TEST_ERROR
+ if(H5Gclose(foo) < 0) TEST_ERROR
+ if((inner = H5Gopen(work, "bar/inner")) < 0) TEST_ERROR
+ if(H5Gclose(inner) < 0) TEST_ERROR
PASSED();
/* Try renaming a symlink */
@@ -370,9 +370,9 @@ test_new_move(hid_t fapl)
if((file_b = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create groups in first file */
- if((grp_1 = H5Gcreate(file_a, "group1", (size_t)0)) < 0) TEST_ERROR
- if((grp_2 = H5Gcreate(file_a, "group2", (size_t)0)) < 0) TEST_ERROR
- if((grp_move = H5Gcreate(grp_1, "group_move", (size_t)0)) < 0) TEST_ERROR
+ if((grp_1 = H5Gcreate2(file_a, "group1", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp_2 = H5Gcreate2(file_a, "group2", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((grp_move = H5Gcreate2(grp_1, "group_move", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create hard and soft links. */
if(H5Glink2(grp_1, "group_move", H5L_TYPE_HARD, H5G_SAME_LOC, "hard") < 0) TEST_ERROR
@@ -886,7 +886,7 @@ test_filespace(hid_t fapl)
if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create a single group to remove */
- if((group = H5Gcreate (file, GROUPNAME, (size_t)0)) < 0) TEST_ERROR
+ if((group = H5Gcreate2(file, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose (group) < 0) TEST_ERROR
/* Remove the group */
@@ -912,7 +912,7 @@ test_filespace(hid_t fapl)
/* Create a many groups to remove */
for(u = 0; u < UNLINK_NGROUPS; u++) {
sprintf(objname, "%s %u", GROUPNAME, u);
- if((group = H5Gcreate(file, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group = H5Gcreate2(file, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose (group) < 0) TEST_ERROR
} /* end for */
@@ -941,8 +941,8 @@ test_filespace(hid_t fapl)
if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create a small group hierarchy to remove */
- if((group = H5Gcreate(file, GROUPNAME, (size_t)0)) < 0) TEST_ERROR
- if((group2 = H5Gcreate (group, GROUP2NAME, (size_t)0)) < 0) TEST_ERROR
+ if((group = H5Gcreate2(file, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
+ if((group2 = H5Gcreate2(group, GROUP2NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose (group2) < 0) TEST_ERROR
if(H5Gclose (group) < 0) TEST_ERROR
@@ -981,13 +981,13 @@ test_filespace(hid_t fapl)
for(u=0; u<FILESPACE_TOP_GROUPS; u++) {
/* Create group */
sprintf(objname,"%s %u",GROUPNAME,u);
- if((group = H5Gcreate (file, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group = H5Gcreate2(file, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create nested groups inside top groups */
for(v=0; v<FILESPACE_NESTED_GROUPS; v++) {
/* Create group */
sprintf(objname,"%s %u",GROUP2NAME,v);
- if((group2 = H5Gcreate (group, objname, (size_t)0)) < 0) TEST_ERROR
+ if((group2 = H5Gcreate2(group, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create datasets inside nested groups */
for(w=0; w<FILESPACE_NDATASETS; w++) {
@@ -1093,12 +1093,12 @@ test_filespace(hid_t fapl)
if ((file=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create a single group to remove */
- if((group = H5Gcreate (file, GROUPNAME, (size_t)0)) < 0) TEST_ERROR
+ if((group = H5Gcreate2(file, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose (group) < 0) TEST_ERROR
/* Create another group with same name */
H5E_BEGIN_TRY {
- group = H5Gcreate (file, GROUPNAME, (size_t)0);
+ group = H5Gcreate2(file, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
} H5E_END_TRY;
if (group>=0) {
H5Gclose(group);
@@ -1249,7 +1249,8 @@ error:
*
*-------------------------------------------------------------------------
*/
-static int test_create_unlink(const char *msg, hid_t fapl)
+static int
+test_create_unlink(const char *msg, hid_t fapl)
{
hid_t file, group;
unsigned u;
@@ -1266,7 +1267,7 @@ static int test_create_unlink(const char *msg, hid_t fapl)
/* Create a many groups to remove */
for(u=0; u<UNLINK_NGROUPS; u++) {
sprintf(groupname,"%s %u",GROUPNAME,u);
- if((group = H5Gcreate (file, groupname, (size_t)0)) < 0) {
+ if((group = H5Gcreate2(file, groupname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) {
H5_FAILED();
printf("group %s creation failed\n", groupname);
goto error;
@@ -1331,10 +1332,10 @@ test_link_slashes(hid_t fapl)
if((fid=H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create a group in the root group */
- if((gid = H5Gcreate(fid, SLASHES_GROUP_NAME, (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(fid, SLASHES_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create a nested group in the root group */
- if((gid2 = H5Gcreate(gid, SLASHES_GROUP_NAME, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, SLASHES_GROUP_NAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Close the nested group */
if(H5Gclose(gid2) < 0) TEST_ERROR
@@ -1500,14 +1501,14 @@ test_unlink_rightleaf(hid_t fid)
/* Create all the groups */
for (n = 0; n < ngroups; n++) {
sprintf(name, "Zone%d", n + 1);
- if((gids[n] = H5Gcreate (rootid, name, (size_t)0)) < 0) TEST_ERROR
+ if((gids[n] = H5Gcreate2(rootid, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
} /* end for */
/* Unlink & re-create each group */
for (n = 0; n < ngroups; n++) {
if(delete_node (rootid, gids[n]) < 0) TEST_ERROR
sprintf(name, "Zone%d", n + 1);
- if((gids[n] = H5Gcreate (rootid, name, (size_t)0)) < 0) TEST_ERROR
+ if((gids[n] = H5Gcreate2(rootid, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
} /* end for */
/* Close all the groups */
@@ -1564,7 +1565,7 @@ test_unlink_rightnode(hid_t fid)
/* Create all the groups */
for (n = 0; n < ngroups; n++) {
sprintf(name, "ZoneB%d", n + 1);
- if((gids[n] = H5Gcreate (rootid, name, (size_t)0)) < 0) TEST_ERROR
+ if((gids[n] = H5Gcreate2(rootid, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
} /* end for */
/* Close all the groups */
@@ -1628,7 +1629,7 @@ test_unlink_middlenode(hid_t fid)
/* Create all the groups */
for (n = 0; n < ngroups; n++) {
sprintf(name, "ZoneC%d", n + 1);
- if((gids[n] = H5Gcreate (rootid, name, (size_t)0)) < 0) TEST_ERROR
+ if((gids[n] = H5Gcreate2(rootid, name, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
} /* end for */
/* Close all the groups */
@@ -1970,7 +1971,7 @@ test_resurrect_group(hid_t fapl)
if((file = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create a group in the file */
- if((group = H5Gcreate (file, GROUPNAME, (size_t)0)) < 0) TEST_ERROR
+ if((group = H5Gcreate2(file, GROUPNAME, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Unlink the group while it's open (will mark it for deletion when closed) */
if(H5Gunlink(file, GROUPNAME) < 0) TEST_ERROR
@@ -2127,12 +2128,12 @@ test_full_group_compact(hid_t fapl)
if((file_id = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group to link objects to */
- if((gid = H5Gcreate(file_id, "/keep", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(file_id, "/keep", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create several objects to link to */
for(u = 0; u < FULL_GROUP_NUM_KEEP; u++) {
sprintf(objname, "keep %u\n", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
} /* end for */
@@ -2149,7 +2150,7 @@ test_full_group_compact(hid_t fapl)
if((file_id = H5Fopen(filename, H5F_ACC_RDWR, fapl)) < 0) TEST_ERROR
/* Create group to delete */
- if((gid = H5Gcreate(file_id, "/delete", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(file_id, "/delete", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create external link (doesn't matter if it dangles) */
if(H5Lcreate_external("foo.h5", "/dst", gid, "external", H5P_DEFAULT, H5P_DEFAULT) < 0) TEST_ERROR
@@ -2167,7 +2168,7 @@ test_full_group_compact(hid_t fapl)
/* Create several objects to delete */
for(u = 0; u < FULL_GROUP_NUM_DELETE_COMPACT; u++) {
sprintf(objname, "delete %u\n", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
} /* end for */
@@ -2261,12 +2262,12 @@ test_full_group_dense(hid_t fapl)
if((file_id = H5Fcreate(filename, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0) TEST_ERROR
/* Create group to link objects to */
- if((gid = H5Gcreate(file_id, "/keep", (size_t)0)) < 0) TEST_ERROR
+ if((gid = H5Gcreate2(file_id, "/keep", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
/* Create several objects to link to */
for(u = 0; u < FULL_GROUP_NUM_KEEP; u++) {
sprintf(objname, "keep %u\n", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
} /* end for */
@@ -2313,7 +2314,7 @@ test_full_group_dense(hid_t fapl)
/* Create several objects to delete */
for(u = 0; u < FULL_GROUP_NUM_DELETE_DENSE; u++) {
sprintf(objname, "delete %u\n", u);
- if((gid2 = H5Gcreate(gid, objname, (size_t)0)) < 0) TEST_ERROR
+ if((gid2 = H5Gcreate2(gid, objname, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT)) < 0) TEST_ERROR
if(H5Gclose(gid2) < 0) TEST_ERROR
} /* end for */