diff options
author | Karl Heuer <kwzh@gnu.org> | 1995-02-03 23:23:34 +0000 |
---|---|---|
committer | Karl Heuer <kwzh@gnu.org> | 1995-02-03 23:23:34 +0000 |
commit | c1f838688fdd71535cda5718c0e5f86d7c0c44a0 (patch) | |
tree | d26f242d20f9e9eca72350eddfc06afa91bdcf6e /src/alloc.c | |
parent | 41ee52d78910d80305ea2b7bb40b060bee24771e (diff) | |
download | emacs-c1f838688fdd71535cda5718c0e5f86d7c0c44a0.tar.gz |
(mark_perdisplays): New function.
(Fgarbage_collect): Call it.
Diffstat (limited to 'src/alloc.c')
-rw-r--r-- | src/alloc.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/src/alloc.c b/src/alloc.c index 1ed27b168f5..f36bf7e3e1e 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -130,7 +130,7 @@ int stack_copy_size; /* Non-zero means ignore malloc warnings. Set during initialization. */ int ignore_warnings; -static void mark_object (), mark_buffer (); +static void mark_object (), mark_buffer (), mark_perdisplays (); static void clear_marks (), gc_sweep (); static void compact_strings (); @@ -1358,6 +1358,7 @@ Garbage collection happens automatically if you cons more than\n\ XMARK (backlist->args[i]); } } + mark_perdisplays (); gc_sweep (); @@ -1777,6 +1778,21 @@ mark_buffer (buf) mark_buffer (base_buffer); } } + + +/* Mark the pointers in the perdisplay objects. */ + +static void +mark_perdisplays () +{ + PERDISPLAY *perd; + for (perd = all_perdisplays; perd; perd = perd->next_perdisplay) + { + mark_object (&perd->Vprefix_arg); + mark_object (&perd->Vcurrent_prefix_arg); + mark_object (&perd->kbd_buffer_frame_or_window); + } +} /* Sweep: find all structures not marked, and free them. */ |