summaryrefslogtreecommitdiffstats
path: root/src/H5MM.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5MM.c')
-rw-r--r--src/H5MM.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/H5MM.c b/src/H5MM.c
index cd246e5..14e847b 100644
--- a/src/H5MM.c
+++ b/src/H5MM.c
@@ -177,7 +177,7 @@ H5MM_xstrdup(const char *s)
FUNC_ENTER_NOAPI_NOINIT_NOFUNC(H5MM_xstrdup)
if(s) {
- ret_value = H5MM_malloc(HDstrlen(s) + 1);
+ ret_value = (char *)H5MM_malloc(HDstrlen(s) + 1);
HDassert(ret_value);
HDstrcpy(ret_value, s);
} /* end if */
@@ -210,17 +210,17 @@ H5MM_strdup(const char *s)
{
char *ret_value;
- FUNC_ENTER_NOAPI(H5MM_strdup, NULL);
+ FUNC_ENTER_NOAPI(H5MM_strdup, NULL)
- if (!s)
- HGOTO_ERROR (H5E_ARGS, H5E_BADVALUE, NULL, "null string");
- if (NULL==(ret_value = H5MM_malloc(HDstrlen(s) + 1)))
- HGOTO_ERROR (H5E_RESOURCE, H5E_NOSPACE, NULL, "memory allocation failed");
+ if(!s)
+ HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, NULL, "null string")
+ if(NULL == (ret_value = (char *)H5MM_malloc(HDstrlen(s) + 1)))
+ HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, NULL, "memory allocation failed")
HDstrcpy(ret_value, s);
done:
- FUNC_LEAVE_NOAPI(ret_value);
-}
+ FUNC_LEAVE_NOAPI(ret_value)
+} /* end H5MM_strdup() */
/*-------------------------------------------------------------------------