summaryrefslogtreecommitdiff
path: root/source4/lib/ldb/common/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/lib/ldb/common/util.c')
-rw-r--r--source4/lib/ldb/common/util.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/source4/lib/ldb/common/util.c b/source4/lib/ldb/common/util.c
index 22bbc8334e..68537a7864 100644
--- a/source4/lib/ldb/common/util.c
+++ b/source4/lib/ldb/common/util.c
@@ -35,24 +35,6 @@
#include "includes.h"
-#define MAX_MALLOC_SIZE 0x7fffffff
-
-/*
- realloc an array, checking for integer overflow in the array size
-*/
-void *realloc_array(void *ptr, size_t el_size, unsigned count)
-{
- if (count == 0 ||
- count >= MAX_MALLOC_SIZE/el_size) {
- return NULL;
- }
- if (!ptr) {
- return malloc(el_size * count);
- }
- return realloc(ptr, el_size * count);
-}
-
-
/*
find an element in a list, using the given comparison function and
assuming that the list is already sorted using comp_fn