summaryrefslogtreecommitdiffstats
path: root/src/H5Tenum.c
diff options
context:
space:
mode:
authorDana Robinson <derobins@hdfgroup.org>2020-08-17 16:12:59 (GMT)
committerDana Robinson <derobins@hdfgroup.org>2020-08-17 16:12:59 (GMT)
commitb2d917437dde37938ce27753b9bf22899bf1f6a9 (patch)
treec1a7ca0939b4959e2a7d438b61466045272fe5aa /src/H5Tenum.c
parentd53c9be189578c63b67b23495e396f21819c373d (diff)
downloadhdf5-b2d917437dde37938ce27753b9bf22899bf1f6a9.zip
hdf5-b2d917437dde37938ce27753b9bf22899bf1f6a9.tar.gz
hdf5-b2d917437dde37938ce27753b9bf22899bf1f6a9.tar.bz2
Minor refactoring based on 1.10 normalization work
Diffstat (limited to 'src/H5Tenum.c')
-rw-r--r--src/H5Tenum.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/H5Tenum.c b/src/H5Tenum.c
index cd41a23..e1d8246 100644
--- a/src/H5Tenum.c
+++ b/src/H5Tenum.c
@@ -191,17 +191,17 @@ H5T__enum_insert(const H5T_t *dt, const char *name, const void *value)
/* The name and value had better not already exist */
for(i = 0; i < dt->shared->u.enumer.nmembs; i++) {
- if(!HDstrcmp(dt->shared->u.enumer.name[i], name))
+ if(!HDstrcmp(dt->shared->u.enumer.name[i], name))
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "name redefinition")
- if(!HDmemcmp((uint8_t *)dt->shared->u.enumer.value + (i * dt->shared->size), value, dt->shared->size))
+ if(!HDmemcmp((uint8_t *)dt->shared->u.enumer.value + (i * dt->shared->size), value, dt->shared->size))
HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "value redefinition")
- } /* end for */
+ }
/* Increase table sizes */
if(dt->shared->u.enumer.nmembs >= dt->shared->u.enumer.nalloc) {
char **names;
uint8_t *values;
- unsigned n = MAX(32, 2*dt->shared->u.enumer.nalloc);
+ unsigned n = MAX(32, 2*dt->shared->u.enumer.nalloc);
if(NULL == (names = (char **)H5MM_realloc(dt->shared->u.enumer.name, n * sizeof(char *))))
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed")
@@ -211,7 +211,7 @@ H5T__enum_insert(const H5T_t *dt, const char *name, const void *value)
HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed")
dt->shared->u.enumer.value = values;
dt->shared->u.enumer.nalloc = n;
- } /* end for */
+ }
/* Insert new member at end of member arrays */
dt->shared->u.enumer.sorted = H5T_SORT_NONE;