From 5e48429a26cf87bdbabc242bc8fce447e3910adf Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20Dj=C3=A4rv?= Date: Mon, 9 Dec 2013 09:23:01 +0100 Subject: [PATCH] * alloc.c (Fmemory_limit): Avoid compiler warning. Return 0 always. --- src/ChangeLog | 4 ++++ src/alloc.c | 5 +++++ 2 files changed, 9 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index e7016c6165b..159bf04075e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2013-12-09 Jan Djärv + + * alloc.c (Fmemory_limit): Avoid compiler warning. Return 0 always. + 2013-12-08 Jan Djärv * nsterm.m (updateFrameSize:): Fix GNUStep toolbar not updating. diff --git a/src/alloc.c b/src/alloc.c index f076075a94f..aeda42637cd 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -6633,7 +6633,12 @@ We divide the value by 1024 to make sure it fits in a Lisp integer. */) { Lisp_Object end; +#ifdef HAVE_NS + /* Avoid warning. sbrk has no relation to memory allocated anyway. */ + XSETINT (end, 0); +#else XSETINT (end, (intptr_t) (char *) sbrk (0) / 1024); +#endif return end; } -- 2.39.2