aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2011-07-12 18:04:29 -0700
committerPaul Eggert2011-07-12 18:04:29 -0700
commit47ea7f442f7d85f29b7200ada8755e6ebf5c0819 (patch)
treea3df6ad9ff1beb86fd7cb8fe8af9ff0bd433c616 /src
parent7152b011c2bae3bfcb7a6d195911ba52e4d112b3 (diff)
downloademacs-47ea7f442f7d85f29b7200ada8755e6ebf5c0819.tar.gz
emacs-47ea7f442f7d85f29b7200ada8755e6ebf5c0819.zip
* alloc.c (gc_sweep): Don't read past end of array.
In theory, the old code could also have corrupted Emacs internals, though it'd be very unlikely.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog6
-rw-r--r--src/alloc.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 07c707eacdc..386ed435b2a 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,9 @@
12011-07-13 Paul Eggert <eggert@cs.ucla.edu>
2
3 * alloc.c (gc_sweep): Don't read past end of array.
4 In theory, the old code could also have corrupted Emacs internals,
5 though it'd be very unlikely.
6
12011-07-12 Andreas Schwab <schwab@linux-m68k.org> 72011-07-12 Andreas Schwab <schwab@linux-m68k.org>
2 8
3 * character.c (Fcharacterp): Don't advertise optional ignored 9 * character.c (Fcharacterp): Don't advertise optional ignored
diff --git a/src/alloc.c b/src/alloc.c
index 6ba080c0b4c..44f935c243d 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -5733,7 +5733,7 @@ gc_sweep (void)
5733 int ilim = (lim + BITS_PER_INT - 1) / BITS_PER_INT; 5733 int ilim = (lim + BITS_PER_INT - 1) / BITS_PER_INT;
5734 5734
5735 /* Scan the mark bits an int at a time. */ 5735 /* Scan the mark bits an int at a time. */
5736 for (i = 0; i <= ilim; i++) 5736 for (i = 0; i < ilim; i++)
5737 { 5737 {
5738 if (cblk->gcmarkbits[i] == -1) 5738 if (cblk->gcmarkbits[i] == -1)
5739 { 5739 {