diff options
author | Robb Matzke <matzke@llnl.gov> | 1998-01-28 21:43:08 (GMT) |
---|---|---|
committer | Robb Matzke <matzke@llnl.gov> | 1998-01-28 21:43:08 (GMT) |
commit | d4a3224c0fde991cdf65392aeeae326c46406121 (patch) | |
tree | 462dea6a59f895530173943dcf18930916868a8b /src/H5P.c | |
parent | c131a549dc1a9c8456d8cf0e44a56187dae1c268 (diff) | |
download | hdf5-d4a3224c0fde991cdf65392aeeae326c46406121.zip hdf5-d4a3224c0fde991cdf65392aeeae326c46406121.tar.gz hdf5-d4a3224c0fde991cdf65392aeeae326c46406121.tar.bz2 |
[svn-r193] Changes since 19980128
----------------------
./MANIFEST
Added new config files.
./src/H5private.h
Changed FUNC_ENTER() so it calls H5Eclear() for all API
functions but not for any private functions. It also prints
the names of all API functions on file 55 (just for the
prototype) so we can get a list of API functions called with
the Bourne shell commands like:
./testhdf5 55>api_list or
./testhdf5 55>&1 1>/dev/null 2>&1 | less
Otherwise the names are silently discarded.
./src/H5.c
./src/H5C.c
./src/H5D.c
./src/H5F.c
./src/H5G.c
./src/H5M.c
./src/H5P.c
./src/H5T.c
Removed `H5ECLEAR' from lots of places in the source code.
./src/H5E.c
./src/H5Eprivate.h
Recursion is a problem here, so to disable a call to
H5Eclear() from FUNC_ENTER just define a local variable like
this before you call FUNC_ENTER:
const H5E_clearable_g = FALSE;
Unfortunately this results in a warning: declaration of
`H5E_clearable_g' shadows global declaration. Good thing it's
only used in two places.
Diffstat (limited to 'src/H5P.c')
-rw-r--r-- | src/H5P.c | 29 |
1 files changed, 6 insertions, 23 deletions
@@ -108,7 +108,6 @@ H5Pcreate_simple(int rank, size_t dims[]) hid_t ret_value = FAIL; FUNC_ENTER(H5Pcreate, FAIL); - H5ECLEAR; ds = H5MM_xcalloc(1, sizeof(H5P_t)); ds->type = H5P_SIMPLE; @@ -160,7 +159,6 @@ H5Pcreate(H5P_class_t type) hid_t ret_value = FAIL; FUNC_ENTER(H5Pcreate, FAIL); - H5ECLEAR; ds = H5MM_xcalloc(1, sizeof(H5P_t)); ds->type = type; @@ -218,9 +216,8 @@ herr_t H5Pclose(hid_t space_id) { FUNC_ENTER(H5Pclose, FAIL); - H5ECLEAR; - /* check args */ + /* Check args */ if (H5_DATASPACE != H5A_group(space_id) || NULL == H5A_object(space_id)) { HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data space"); @@ -376,9 +373,8 @@ H5Pget_npoints(hid_t space_id) size_t ret_value = 0; FUNC_ENTER(H5Pget_npoints, 0); - H5ECLEAR; - /* check args */ + /* Check args */ if (H5_DATASPACE != H5A_group(space_id) || NULL == (ds = H5A_object(space_id))) { HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, 0, "not a data space"); @@ -472,9 +468,8 @@ H5Pget_ndims(hid_t space_id) size_t ret_value = 0; FUNC_ENTER(H5Pget_ndims, FAIL); - H5ECLEAR; - /* check args */ + /* Check args */ if (H5_DATASPACE != H5A_group(space_id) || NULL == (ds = H5A_object(space_id))) { HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data space"); @@ -559,9 +554,8 @@ H5Pget_dims(hid_t space_id, size_t dims[]/*out*/) size_t ret_value = 0; FUNC_ENTER(H5Pget_dims, FAIL); - H5ECLEAR; - /* check args */ + /* Check args */ if (H5_DATASPACE != H5A_group(space_id) || NULL == (ds = H5A_object(space_id))) { HRETURN_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data space"); @@ -834,9 +828,7 @@ H5P_is_simple(const H5P_t *sdim) FUNC_ENTER(H5P_is_simple, FAIL); - /* Clear errors and check args and all the boring stuff. */ - H5ECLEAR; - + /* Check args and all the boring stuff. */ assert(sdim); ret_value = sdim->type == H5P_SIMPLE ? TRUE : FALSE; /* Currently all dataspaces are simple, but check anyway */ @@ -866,9 +858,7 @@ H5Pis_simple(hid_t sid) FUNC_ENTER(H5Pis_simple, FAIL); - /* Clear errors and check args and all the boring stuff. */ - H5ECLEAR; - + /* Check args and all the boring stuff. */ if ((space = H5A_object(sid)) == NULL) HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "not a data space"); @@ -913,9 +903,6 @@ H5Pset_space(hid_t sid, int rank, const size_t *dims) FUNC_ENTER(H5Pset_space, FAIL); - /* Clear errors and check args and all the boring stuff. */ - H5ECLEAR; - /* Get the object */ if ((space = H5A_object(sid)) == NULL) HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "not a data space"); @@ -1035,9 +1022,6 @@ H5Pset_hyperslab(hid_t sid, const intn *start, const intn *count, const intn *st FUNC_ENTER(H5Pset_hyperslab, FAIL); - /* Clear errors and check args and all the boring stuff. */ - H5ECLEAR; - /* Get the object */ if (H5_DATASPACE != H5A_group(sid) || (space = H5A_object(sid)) == NULL) HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "not a data space"); @@ -1116,7 +1100,6 @@ H5Pget_hyperslab (hid_t sid, int offset[]/*out*/, int size[]/*out*/, intn ret_value = FAIL; FUNC_ENTER (H5Pget_hyperslab, FAIL); - H5ECLEAR; /* Check args */ if (H5_DATASPACE!=H5A_group (sid) || NULL==(ds=H5A_object (sid))) { |