summaryrefslogtreecommitdiffstats
path: root/src/H5MMprivate.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5MMprivate.h')
-rw-r--r--src/H5MMprivate.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/H5MMprivate.h b/src/H5MMprivate.h
index 54dfbfb..9aadd36 100644
--- a/src/H5MMprivate.h
+++ b/src/H5MMprivate.h
@@ -32,18 +32,19 @@
/* Private headers needed by this file */
#include "H5private.h"
-#ifdef H5_MALLOC_WORKS
+#ifdef NDEBUG
#define H5MM_malloc(Z) HDmalloc(Z)
#define H5MM_calloc(Z) HDcalloc(1,Z)
-#else /* H5_MALLOC_WORKS */
-#define H5MM_malloc(Z) HDmalloc(MAX(1,Z))
-#define H5MM_calloc(Z) HDcalloc(1,MAX(1,Z))
-#endif /* H5_MALLOC_WORKS */
+#endif /* NDEBUG */
#define H5MM_free(Z) HDfree(Z)
/*
* Library prototypes...
*/
+#ifndef NDEBUG
+H5_DLL void *H5MM_malloc(size_t size);
+H5_DLL void *H5MM_calloc(size_t size);
+#endif /* NDEBUG */
H5_DLL void *H5MM_realloc(void *mem, size_t size);
H5_DLL char *H5MM_xstrdup(const char *s);
H5_DLL char *H5MM_strdup(const char *s);