summaryrefslogtreecommitdiffstats
path: root/src/H5S.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5S.c')
-rw-r--r--src/H5S.c51
1 files changed, 1 insertions, 50 deletions
diff --git a/src/H5S.c b/src/H5S.c
index 747d297..13d32cf 100644
--- a/src/H5S.c
+++ b/src/H5S.c
@@ -84,7 +84,7 @@ H5FL_ARR_DEFINE(hsize_t, H5S_MAX_RANK);
static const H5I_class_t H5I_DATASPACE_CLS[1] = {{
H5I_DATASPACE, /* ID class value */
0, /* Class flags */
- 2, /* # of reserved IDs for class */
+ 3, /* # of reserved IDs for class */
(H5I_free_t)H5S__close_cb /* Callback routine for closing objects of this class */
}};
@@ -277,55 +277,6 @@ done:
/*--------------------------------------------------------------------------
NAME
- H5S_get_validiated_dataspace
- PURPOSE
- Get a pointer to a validated H5S_t pointer
- USAGE
- H5S_t *H5S_get_validated_space(dataspace_id, space)
- hid_t space_id; IN: The ID of the dataspace
- const H5S_t * space; OUT: A pointer to the dataspace
- RETURNS
- SUCCEED/FAIL
- DESCRIPTION
- Gets a pointer to a dataspace struct after validating it. The pointer
- can be NULL (if the ID is H5S_ALL, for example).
- GLOBAL VARIABLES
- COMMENTS, BUGS, ASSUMPTIONS
- EXAMPLES
- REVISION LOG
---------------------------------------------------------------------------*/
-herr_t
-H5S_get_validated_dataspace(hid_t space_id, const H5S_t **space)
-{
- herr_t ret_value = SUCCEED; /* Return value */
-
- FUNC_ENTER_NOAPI(FAIL)
-
- HDassert(space);
-
- /* Check for invalid ID */
- if (space_id < 0)
- HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "invalid space_id (ID cannot be a negative number)")
-
- /* No special dataspace struct for H5S_ALL */
- if (H5S_ALL == space_id)
- *space = NULL;
- else {
- /* Get the dataspace pointer */
- if (NULL == (*space = (const H5S_t *)H5I_object_verify(space_id, H5I_DATASPACE)))
- HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "space_id is not a dataspace ID")
-
- /* Check for valid selection */
- if (H5S_SELECT_VALID(*space) != TRUE)
- HGOTO_ERROR(H5E_DATASPACE, H5E_BADRANGE, FAIL, "selection + offset not within extent")
- }
-
-done:
- FUNC_LEAVE_NOAPI(ret_value)
-} /* end H5S_get_validated_dataspace() */
-
-/*--------------------------------------------------------------------------
- NAME
H5S_create
PURPOSE
Create empty, typed dataspace