emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Memory leak in keyboard variables?


From: Stefan Monnier
Subject: Re: Memory leak in keyboard variables?
Date: Thu, 11 Dec 2008 10:59:56 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

> Now, input-decode-map is defined in keyboard.c, using DEFVAR_KBOARD.  It
> is a Lisp_Misc_Kboard_Objfwd object, and if I'm not mistaken, such
> objects are not garbage-collected.

No, indeed, they're not GC'd: they're static.

> When the terminal is killed, are its keyboard's Lisp_Misc_Kboard_Objfwd
> objects freed?  As far as I can tell, they are not freed.  But I am no
> expert in this part of the code, so maybe someone else can clue me in.

The Lisp_Misc_Kboard_Objfwd only stores the location of the Lisp_Object
slot in the keyboard objects.  So the objects will becomes unreachable
when the keyboard object is freed.
Maybe the keyboard object is not freed when the terminal is freed?


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]