summaryrefslogtreecommitdiffstats
path: root/test/lheap.c
diff options
context:
space:
mode:
authorRaymond Lu <songyulu@hdfgroup.org>2004-09-01 17:43:30 (GMT)
committerRaymond Lu <songyulu@hdfgroup.org>2004-09-01 17:43:30 (GMT)
commitcb7f03a26ff906175e5bf37af57547681683770f (patch)
treed8d167353c83fe6caebc6df15c33ca1c7f6dc521 /test/lheap.c
parent226f162ce75ff63e3d1468d17528ba629c51db58 (diff)
downloadhdf5-cb7f03a26ff906175e5bf37af57547681683770f.zip
hdf5-cb7f03a26ff906175e5bf37af57547681683770f.tar.gz
hdf5-cb7f03a26ff906175e5bf37af57547681683770f.tar.bz2
[svn-r9183] Purpose: New feature
Description: Restore 6 old error API functions back to the library to be backward compatible with v1.6. They are H5Epush, H5Eprint, H5Ewalk, H5Eclear, H5Eset_auto, H5Eget_auto. These functions do not have error stack as parameter. Solution: Internally, these functions use default error stack. Platforms tested: h5committest and fuss. Misc. update: RELEASE.txt
Diffstat (limited to 'test/lheap.c')
-rw-r--r--test/lheap.c42
1 files changed, 7 insertions, 35 deletions
diff --git a/test/lheap.c b/test/lheap.c
index e1694ba..76c11a0 100644
--- a/test/lheap.c
+++ b/test/lheap.c
@@ -74,20 +74,12 @@ main(void)
goto error;
if (NULL==(f=H5I_object(file))) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
if (H5HL_create(f, H5P_DATASET_XFER_DEFAULT, 0, &heap_addr/*out*/)<0) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
for (i = 0; i < NOBJS; i++) {
@@ -98,11 +90,7 @@ main(void)
if ((size_t)(-1)==(obj[i]=H5HL_insert(f, H5P_DATASET_XFER_DEFAULT, heap_addr, strlen(buf)+1,
buf))) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
}
@@ -118,11 +106,7 @@ main(void)
if ((file=H5Fopen(filename, H5F_ACC_RDONLY, fapl))<0) goto error;
if (NULL==(f=H5I_object(file))) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
for (i=0; i<NOBJS; i++) {
@@ -134,21 +118,13 @@ main(void)
if (NULL == (heap = H5HL_protect(f, H5P_DATASET_XFER_DEFAULT, heap_addr))) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
if (NULL == (s = H5HL_offset_into(f, heap, obj[i]))) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
@@ -162,11 +138,7 @@ main(void)
if (H5HL_unprotect(f, H5P_DATASET_XFER_DEFAULT, heap, heap_addr) < 0) {
H5_FAILED();
-#ifdef H5_WANT_H5_V1_6_COMPAT
- H5Eprint(stdout);
-#else
- H5Eprint(H5E_DEFAULT, stdout);
-#endif /* H5_WANT_H5_V1_6_COMPAT */
+ H5Eprint_stack(H5E_DEFAULT, stdout);
goto error;
}
}