mirror of
https://github.com/Unidata/netcdf-c.git
synced 2025-01-24 16:04:40 +08:00
no longer delete/re-create att if we dont have to
This commit is contained in:
parent
e7b7430e75
commit
0ad7118064
@ -656,15 +656,15 @@ put_att_grpa(NC_GRP_INFO_T *grp, int varid, NC_ATT_INFO_T *att)
|
||||
BAIL(NC_EATTMETA);
|
||||
|
||||
/* Delete the attribute. */
|
||||
/* if (file_typeid != existing_att_typeid && npoints != att->len) */
|
||||
if (file_typeid != existing_att_typeid || npoints != att->len)
|
||||
{
|
||||
if (H5Adelete(locid, att->hdr.name) < 0)
|
||||
BAIL(NC_EHDFERR);
|
||||
}
|
||||
/* else */
|
||||
/* { */
|
||||
/* reuse_att++; */
|
||||
/* } */
|
||||
else
|
||||
{
|
||||
reuse_att++;
|
||||
}
|
||||
}
|
||||
|
||||
/* Create the attribute. */
|
||||
|
Loading…
Reference in New Issue
Block a user