From: Dave Love Date: Mon, 25 Sep 2000 21:09:14 +0000 (+0000) Subject: (__malloc_size_t) [DOUG_LEA_MALLOC]: Don't redefine it. X-Git-Tag: emacs-pretest-21.0.90~1382 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3e60b029bc9d8e909114144e6362a62b19d164dc;p=emacs.git (__malloc_size_t) [DOUG_LEA_MALLOC]: Don't redefine it. (__malloc_size_t) [!DOUG_LEA_MALLOC]: Define unconditionally as size_t. (__malloc_extra_blocks): Declare as __malloc_size_t. --- diff --git a/src/ChangeLog b/src/ChangeLog index 5614b421a56..0ea8211132a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,16 @@ +2000-09-25 Dave Love + + * buffer.c: Include stdio.h. + + Partly suggested by Eduardo Horvath . + + * ralloc.c (__malloc_extra_blocks): Declare as __malloc_size_t. + + * alloc.c (__malloc_size_t) [DOUG_LEA_MALLOC]: Don't redefine it. + (__malloc_size_t) [!DOUG_LEA_MALLOC]: Define unconditionally as + size_t. + (__malloc_extra_blocks): Declare as __malloc_size_t. + 2000-09-25 Gerd Moellmann * alloc.c (mark_image): Use GC_NILP instead of NILP. diff --git a/src/alloc.c b/src/alloc.c index 5f08cd07d81..eaf883a7821 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -52,7 +52,10 @@ extern POINTER_TYPE *sbrk (); #ifdef DOUG_LEA_MALLOC #include +/* malloc.h #defines this as size_t, at least in glibc2. */ +#ifndef __malloc_size_t #define __malloc_size_t int +#endif /* Specify maximum number of areas to mmap. It would be nice to use a value that explicitly means "no limit". */ @@ -63,14 +66,9 @@ extern POINTER_TYPE *sbrk (); /* The following come from gmalloc.c. */ -#if defined (STDC_HEADERS) -#include #define __malloc_size_t size_t -#else -#define __malloc_size_t unsigned int -#endif extern __malloc_size_t _bytes_used; -extern int __malloc_extra_blocks; +extern __malloc_size_t __malloc_extra_blocks; #endif /* not DOUG_LEA_MALLOC */ @@ -3769,7 +3767,7 @@ mark_image (img) { mark_object (&img->spec); - if (!GC_NILP (img->data.lisp_val)) + if (!NILP (img->data.lisp_val)) mark_object (&img->data.lisp_val); }