From: Dave Love Date: Thu, 17 Aug 2000 14:01:09 +0000 (+0000) Subject: (lisp_malloc): Declare with POINTER_TYPE. X-Git-Tag: emacs-pretest-21.0.90~2209 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=b3303f74684a153fc48d2b1622760eca133ba0b2;p=emacs.git (lisp_malloc): Declare with POINTER_TYPE. [SYSTEM_MALLOC]: Make decls in malloc.h conditional on DOUG_LEA_MALLOC. --- diff --git a/src/alloc.c b/src/alloc.c index b955c951ec8..fa6a4c2394c 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -286,7 +286,7 @@ enum mem_type Lisp_Object Vdead; struct mem_node; -static void *lisp_malloc P_ ((size_t, enum mem_type)); +static POINTER_TYPE *lisp_malloc P_ ((size_t, enum mem_type)); static void lisp_free P_ ((POINTER_TYPE *)); static void mark_stack P_ ((void)); static void init_stack P_ ((Lisp_Object *)); @@ -541,15 +541,15 @@ lisp_free (block) GNU malloc. */ #ifndef SYSTEM_MALLOC - -extern void * (*__malloc_hook) (); +#ifndef DOUG_LEA_MALLOC +extern void * (*__malloc_hook) P_ ((size_t)); +extern void * (*__realloc_hook) P_ ((void *, size_t)); +extern void (*__free_hook) P_ ((void *)); +/* Else declared in malloc.h, perhaps with an extra arg. */ +#endif /* DOUG_LEA_MALLOC */ static void * (*old_malloc_hook) (); -extern void * (*__realloc_hook) (); static void * (*old_realloc_hook) (); -extern void (*__free_hook) (); static void (*old_free_hook) (); -static void *emacs_blocked_malloc P_ ((size_t)); -static void *emacs_blocked_realloc P_ ((void *, size_t)); /* This function is used as the hook for free to call. */