At 08:52 PM 12/1/99 +0100, Jan Vroonhof wrote:
> -b20 and -b22 are leaking widgets when running Gnus.
It seems I wasn't invalidating the subwindow cache often enough so that
widgets wouldn't get GC'd until some major change happened to the frame
(which wouldn't happen while you were reading news). The attached patch
fixes this and at least fixes Jan's test case, I hope it makes things
better generally.
andy
1999-12-05 Andy Piper <andy(a)xemacs.org>
* window.c (Fdelete_window): mark subwindows as changed so that
they can be GC'd if necessary.
Index: src/window.c
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs/src/window.c,v
retrieving revision 1.41.2.22
diff -u -r1.41.2.22 window.c
--- src/window.c 1999/10/24 10:26:44 1.41.2.22
+++ src/window.c 1999/12/05 21:41:34
@@ -1865,6 +1865,12 @@
par = XWINDOW (parent);
MARK_FRAME_WINDOWS_STRUCTURE_CHANGED (f);
+ /* It's quite likely that deleting a window will result in
+ subwindows needing to be deleted also (since they are cached
+ per-window). So we mark them as changed, so that the cachels will
+ get reset by redisplay and thus deleted subwindows can get
+ GC'd. */
+ MARK_FRAME_SUBWINDOWS_CHANGED (f);
/* Are we trying to delete any frame's selected window?
Note that we could be dealing with a non-leaf window
--------------------------------------------------------------
Dr Andy Piper
Senior Consultant Architect, BEA Systems Ltd