diff options
Diffstat (limited to 'src/H5A.c')
-rw-r--r-- | src/H5A.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -224,6 +224,10 @@ H5A_create(const H5G_entry_t *ent, const char *name, const H5T_t *type, assert(type); assert(space); + /* Check if the dataspace has an extent set (or is NULL) */ + if( !(H5S_has_extent(space)) ) + HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "dataspace extent has not been set") + /* Build the attribute information */ if((attr = H5MM_calloc(sizeof(H5A_t)))==NULL) HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for attribute info") |