diff options
| author | Dave Love | 2000-08-14 14:15:44 +0000 |
|---|---|---|
| committer | Dave Love | 2000-08-14 14:15:44 +0000 |
| commit | bf952fb6449772186914a0324732782bc2900d48 (patch) | |
| tree | 162084d2df2cca1962b25b1946ecee6a236bdfb8 /src/alloc.c | |
| parent | 0cde14243fa27e86a14ba4069f858149f20f2537 (diff) | |
| download | emacs-bf952fb6449772186914a0324732782bc2900d48.tar.gz emacs-bf952fb6449772186914a0324732782bc2900d48.zip | |
[HAVE_UNISTD_H]: Include unistd.h; don't declare sbrk.
[!HAVE_UNISTD_H]: Use POINTER_TYPE to declare sbrk.
(lisp_free): Declare and make static.
Diffstat (limited to 'src/alloc.c')
| -rw-r--r-- | src/alloc.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/alloc.c b/src/alloc.c index b7c61b4bd07..497c01c707d 100644 --- a/src/alloc.c +++ b/src/alloc.c | |||
| @@ -43,7 +43,11 @@ Boston, MA 02111-1307, USA. */ | |||
| 43 | #include "syssignal.h" | 43 | #include "syssignal.h" |
| 44 | #include <setjmp.h> | 44 | #include <setjmp.h> |
| 45 | 45 | ||
| 46 | extern char *sbrk (); | 46 | #ifdef HAVE_UNISTD_H |
| 47 | #include <unistd.h> | ||
| 48 | #else | ||
| 49 | extern POINTER_TYPE *sbrk (); | ||
| 50 | #endif | ||
| 47 | 51 | ||
| 48 | #ifdef DOUG_LEA_MALLOC | 52 | #ifdef DOUG_LEA_MALLOC |
| 49 | 53 | ||
| @@ -283,6 +287,7 @@ Lisp_Object Vdead; | |||
| 283 | 287 | ||
| 284 | struct mem_node; | 288 | struct mem_node; |
| 285 | static void *lisp_malloc P_ ((size_t, enum mem_type)); | 289 | static void *lisp_malloc P_ ((size_t, enum mem_type)); |
| 290 | static void lisp_free P_ ((POINTER_TYPE *)); | ||
| 286 | static void mark_stack P_ ((void)); | 291 | static void mark_stack P_ ((void)); |
| 287 | static void init_stack P_ ((Lisp_Object *)); | 292 | static void init_stack P_ ((Lisp_Object *)); |
| 288 | static int live_vector_p P_ ((struct mem_node *, void *)); | 293 | static int live_vector_p P_ ((struct mem_node *, void *)); |
| @@ -512,7 +517,7 @@ allocate_buffer () | |||
| 512 | /* Free BLOCK. This must be called to free memory allocated with a | 517 | /* Free BLOCK. This must be called to free memory allocated with a |
| 513 | call to lisp_malloc. */ | 518 | call to lisp_malloc. */ |
| 514 | 519 | ||
| 515 | void | 520 | static void |
| 516 | lisp_free (block) | 521 | lisp_free (block) |
| 517 | POINTER_TYPE *block; | 522 | POINTER_TYPE *block; |
| 518 | { | 523 | { |