From 014319c70488e9d50848af147fdb4832d4e1b1c6 Mon Sep 17 00:00:00 2001 From: Quincey Koziol Date: Sat, 17 Apr 2004 15:33:31 -0500 Subject: [svn-r8380] Purpose: Added new files Description: Corrected code to issue an error when an attribute's dataspace is not able to be understood by the library. Platforms tested: FreeBSD 4.9 (sleipnir) h5committest Misc. update: --- src/H5Oattr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/H5Oattr.c b/src/H5Oattr.c index a75c127..f5bd52b 100644 --- a/src/H5Oattr.c +++ b/src/H5Oattr.c @@ -195,9 +195,9 @@ H5O_attr_decode(H5F_t *f, hid_t dxpl_id, const uint8_t *p, H5O_shared_t UNUSED * nelem*=attr->ds->extent.u.simple.size[u]; attr->ds->extent.nelem = nelem; } else { - attr->ds->extent.type = H5S_SCALAR; - attr->ds->extent.nelem = 1; + HGOTO_ERROR(H5E_ATTR, H5E_CANTDECODE, NULL, "can't decode attribute dataspace"); } + /* Default to entire dataspace being selected */ if(H5S_select_all(attr->ds,0)<0) HGOTO_ERROR (H5E_DATASPACE, H5E_CANTSET, NULL, "unable to set all selection"); -- cgit v0.12