]> git.sur5r.net Git - openldap/commitdiff
Don't do pointer arithmetic on void pointers.
authorHallvard Furuseth <hallvard@openldap.org>
Thu, 22 May 2003 21:52:02 +0000 (21:52 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Thu, 22 May 2003 21:52:02 +0000 (21:52 +0000)
servers/slapd/sl_malloc.c

index 11defd06d4a42163a34c3ad106d182ee27336888..947e2967a17edaada83c0461cb1168ac840f177a 100644 (file)
@@ -79,7 +79,7 @@ sl_mem_detach(
 )
 {
        struct slab_heap *sh = memctx;
-       int size = sh->h_end - sh->h_base;
+       int size = (char *) sh->h_end - (char *) sh->h_base;
 
        sh->h_base = ch_realloc( sh->h_base, size );