From b609f5916da6c2fc66864b390e05e807d85ea88f Mon Sep 17 00:00:00 2001 From: YAMAMOTO Mitsuharu Date: Sun, 21 Nov 2010 19:43:53 -0500 Subject: [PATCH] * alloc.c (mark_maybe_object): Return early if given a Lisp integer (Bug#6301). --- src/ChangeLog | 5 +++++ src/alloc.c | 10 ++++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 44dc63fd424..d9aad77fc7c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2010-11-22 YAMAMOTO Mitsuharu + + * alloc.c (mark_maybe_object): Return early if given a Lisp + integer (Bug#6301). + 2010-11-21 Ken Brown * sheap.c (STATIC_HEAP_SIZE): Revert previous change. diff --git a/src/alloc.c b/src/alloc.c index 6e121212b14..28636ec776c 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -3986,8 +3986,14 @@ DEFUN ("gc-status", Fgc_status, Sgc_status, 0, 0, "", static INLINE void mark_maybe_object (Lisp_Object obj) { - void *po = (void *) XPNTR (obj); - struct mem_node *m = mem_find (po); + void *po; + struct mem_node *m; + + if (INTEGERP (obj)) + return; + + po = (void *) XPNTR (obj); + m = mem_find (po); if (m != MEM_NIL) { -- 2.39.2