summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/util/util.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/source4/lib/util/util.c b/source4/lib/util/util.c
index b5bb75358e..5fc785d642 100644
--- a/source4/lib/util/util.c
+++ b/source4/lib/util/util.c
@@ -582,6 +582,15 @@ _PUBLIC_ void *realloc_array(void *ptr, size_t el_size, unsigned count)
return realloc(ptr, el_size * count);
}
+/****************************************************************************
+ Type-safe malloc.
+****************************************************************************/
+
+void *malloc_array(size_t el_size, unsigned int count)
+{
+ return realloc_array(NULL, el_size, count);
+}
+
_PUBLIC_ void *talloc_check_name_abort(const void *ptr, const char *name)
{
void *result;