PATCH 21.5
This patch plugs a memory leak in keymap.c.
src/ChangeLog addition:
2006-08-03 Jerry James <james(a)xemacs.org>
* keymap.c (where_is_recursive_mapper): Use the freshly allocated
storage instead of leaking it.
xemacs-21.5 source patch:
Diff command: cvs -q diff -uN
Files affected: src/keymap.c
Index: src/keymap.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/keymap.c,v
retrieving revision 1.61
diff -d -u -r1.61 keymap.c
--- src/keymap.c 2005/11/26 13:20:23 1.61
+++ src/keymap.c 2006/08/03 16:27:12
@@ -3754,6 +3754,8 @@
Lisp_Key_Data *new_ = xnew_array (Lisp_Key_Data, size);
memcpy ((void *)new_, (const void *)c->keys_so_far,
c->keys_so_far_total_size * sizeof (Lisp_Key_Data));
+ xfree (c->keys_so_far, Lisp_Key_Data);
+ c->keys_so_far = new_;
}
else
XREALLOC_ARRAY (c->keys_so_far, Lisp_Key_Data, size);
--
Jerry James, Assistant Professor james(a)xemacs.org
Computer Science Department
http://www.cs.usu.edu/~jerry/
Utah State University