aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorEli Zaretskii2012-10-07 20:33:10 +0200
committerEli Zaretskii2012-10-07 20:33:10 +0200
commit98daa89356f6523c2c6663110d0c715f018b1a8b (patch)
tree1a623875528879dddf2e64efee8e10c0ca22fae1 /src
parent0aada74e88baf554a1bf95bce9373d9ac76429ad (diff)
downloademacs-98daa89356f6523c2c6663110d0c715f018b1a8b.tar.gz
emacs-98daa89356f6523c2c6663110d0c715f018b1a8b.zip
Don't abort when ralloc.c:relinquish cannot return a heap to the system.
src/ralloc.c (relinquish): If a heap is ready to be relinquished, but it still has blocs in it, don't return it to the system, instead of aborting. (Bug#12402)
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog6
-rw-r--r--src/ralloc.c5
2 files changed, 9 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 526043c158e..29e831a2eb8 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,9 @@
12012-10-07 Eli Zaretskii <eliz@gnu.org>
2
3 * ralloc.c (relinquish): If a heap is ready to be relinquished,
4 but it still has blocs in it, don't return it to the system,
5 instead of aborting. (Bug#12402)
6
12012-10-07 Jan Djärv <jan.h.d@swipnet.se> 72012-10-07 Jan Djärv <jan.h.d@swipnet.se>
2 8
3 * nsterm.m (ns_dumpglyphs_image): Only draw slice of image (Bug#12506). 9 * nsterm.m (ns_dumpglyphs_image): Only draw slice of image (Bug#12506).
diff --git a/src/ralloc.c b/src/ralloc.c
index e4a8fe9c6da..11897411930 100644
--- a/src/ralloc.c
+++ b/src/ralloc.c
@@ -327,10 +327,11 @@ relinquish (void)
327 327
328 if ((char *)last_heap->end - (char *)last_heap->bloc_start <= excess) 328 if ((char *)last_heap->end - (char *)last_heap->bloc_start <= excess)
329 { 329 {
330 /* This heap should have no blocs in it. */ 330 /* This heap should have no blocs in it. If it does, we
331 cannot return it to the system. */
331 if (last_heap->first_bloc != NIL_BLOC 332 if (last_heap->first_bloc != NIL_BLOC
332 || last_heap->last_bloc != NIL_BLOC) 333 || last_heap->last_bloc != NIL_BLOC)
333 emacs_abort (); 334 return;
334 335
335 /* Return the last heap, with its header, to the system. */ 336 /* Return the last heap, with its header, to the system. */
336 excess = (char *)last_heap->end - (char *)last_heap->start; 337 excess = (char *)last_heap->end - (char *)last_heap->start;