aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/alloc.c')
-rw-r--r--src/alloc.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/alloc.c b/src/alloc.c
index a79751f6213..a0c06a5c35b 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -3114,7 +3114,8 @@ live_string_p (m, p)
3114 3114
3115 /* P must point to the start of a Lisp_String structure, and it 3115 /* P must point to the start of a Lisp_String structure, and it
3116 must not be on the free-list. */ 3116 must not be on the free-list. */
3117 return (offset % sizeof b->strings[0] == 0 3117 return (offset >= 0
3118 && offset % sizeof b->strings[0] == 0
3118 && ((struct Lisp_String *) p)->data != NULL); 3119 && ((struct Lisp_String *) p)->data != NULL);
3119 } 3120 }
3120 else 3121 else
@@ -3138,7 +3139,8 @@ live_cons_p (m, p)
3138 /* P must point to the start of a Lisp_Cons, not be 3139 /* P must point to the start of a Lisp_Cons, not be
3139 one of the unused cells in the current cons block, 3140 one of the unused cells in the current cons block,
3140 and not be on the free-list. */ 3141 and not be on the free-list. */
3141 return (offset % sizeof b->conses[0] == 0 3142 return (offset >= 0
3143 && offset % sizeof b->conses[0] == 0
3142 && (b != cons_block 3144 && (b != cons_block
3143 || offset / sizeof b->conses[0] < cons_block_index) 3145 || offset / sizeof b->conses[0] < cons_block_index)
3144 && !EQ (((struct Lisp_Cons *) p)->car, Vdead)); 3146 && !EQ (((struct Lisp_Cons *) p)->car, Vdead));
@@ -3164,7 +3166,8 @@ live_symbol_p (m, p)
3164 /* P must point to the start of a Lisp_Symbol, not be 3166 /* P must point to the start of a Lisp_Symbol, not be
3165 one of the unused cells in the current symbol block, 3167 one of the unused cells in the current symbol block,
3166 and not be on the free-list. */ 3168 and not be on the free-list. */
3167 return (offset % sizeof b->symbols[0] == 0 3169 return (offset >= 0
3170 && offset % sizeof b->symbols[0] == 0
3168 && (b != symbol_block 3171 && (b != symbol_block
3169 || offset / sizeof b->symbols[0] < symbol_block_index) 3172 || offset / sizeof b->symbols[0] < symbol_block_index)
3170 && !EQ (((struct Lisp_Symbol *) p)->function, Vdead)); 3173 && !EQ (((struct Lisp_Symbol *) p)->function, Vdead));
@@ -3190,7 +3193,8 @@ live_float_p (m, p)
3190 /* P must point to the start of a Lisp_Float, not be 3193 /* P must point to the start of a Lisp_Float, not be
3191 one of the unused cells in the current float block, 3194 one of the unused cells in the current float block,
3192 and not be on the free-list. */ 3195 and not be on the free-list. */
3193 return (offset % sizeof b->floats[0] == 0 3196 return (offset >= 0
3197 && offset % sizeof b->floats[0] == 0
3194 && (b != float_block 3198 && (b != float_block
3195 || offset / sizeof b->floats[0] < float_block_index) 3199 || offset / sizeof b->floats[0] < float_block_index)
3196 && !EQ (((struct Lisp_Float *) p)->type, Vdead)); 3200 && !EQ (((struct Lisp_Float *) p)->type, Vdead));
@@ -3216,7 +3220,8 @@ live_misc_p (m, p)
3216 /* P must point to the start of a Lisp_Misc, not be 3220 /* P must point to the start of a Lisp_Misc, not be
3217 one of the unused cells in the current misc block, 3221 one of the unused cells in the current misc block,
3218 and not be on the free-list. */ 3222 and not be on the free-list. */
3219 return (offset % sizeof b->markers[0] == 0 3223 return (offset >= 0
3224 && offset % sizeof b->markers[0] == 0
3220 && (b != marker_block 3225 && (b != marker_block
3221 || offset / sizeof b->markers[0] < marker_block_index) 3226 || offset / sizeof b->markers[0] < marker_block_index)
3222 && ((union Lisp_Misc *) p)->u_marker.type != Lisp_Misc_Free); 3227 && ((union Lisp_Misc *) p)->u_marker.type != Lisp_Misc_Free);