aboutsummaryrefslogtreecommitdiffstats
path: root/src/alloc.c
diff options
context:
space:
mode:
authorPaul Eggert2019-03-02 11:05:40 -0800
committerPaul Eggert2019-03-02 11:06:40 -0800
commit5f99d515c921ee5546483ddab15e08f9b23280d9 (patch)
tree7e00ad4f2be6ec0c6b0cc602c54aa9199d67740a /src/alloc.c
parent954c9c5bc344cdd6b201c2260b306ec0999aff24 (diff)
downloademacs-5f99d515c921ee5546483ddab15e08f9b23280d9.tar.gz
emacs-5f99d515c921ee5546483ddab15e08f9b23280d9.zip
Avoid staticvec duplicates
* src/alloc.c (staticpro) [ENABLE_CHECKING]: Check for duplicates. * src/keyboard.c (syms_of_keyboard): Define while-no-input-ignore-events and inhibit--record-char here ... (syms_of_keyboard_for_pdumper): ... instead of here. This avoids duplicates in staticvec.
Diffstat (limited to 'src/alloc.c')
-rw-r--r--src/alloc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/alloc.c b/src/alloc.c
index 7d63e3c79b6..452d31f9398 100644
--- a/src/alloc.c
+++ b/src/alloc.c
@@ -5725,6 +5725,8 @@ purecopy (Lisp_Object obj)
5725void 5725void
5726staticpro (Lisp_Object *varaddress) 5726staticpro (Lisp_Object *varaddress)
5727{ 5727{
5728 for (int i = 0; i < staticidx; i++)
5729 eassert (staticvec[i] != varaddress);
5728 if (staticidx >= NSTATICS) 5730 if (staticidx >= NSTATICS)
5729 fatal ("NSTATICS too small; try increasing and recompiling Emacs."); 5731 fatal ("NSTATICS too small; try increasing and recompiling Emacs.");
5730 staticvec[staticidx++] = varaddress; 5732 staticvec[staticidx++] = varaddress;