bug-gnu-emacs
[Top][All Lists]
Advanced

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

space leak in require


From: Dave Love
Subject: space leak in require
Date: 27 Nov 2002 12:22:03 +0000
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2

Calls of `require' for already-provided features cause
`current-load-list' to grow without limit.  As far as I can tell,
there's no reason always to call LOADHIST_ATTACH.

2002-11-27  Dave Love  <fx@gnu.org>

        * fns.c (Frequire): Don't call LOADHIST_ATTACH if feature was
        already provided.

*** fns.c.~1.286.4.1.~  Fri Oct 11 19:40:14 2002
--- fns.c       Wed Nov 27 12:08:10 2002
***************
*** 3076,3087 ****
    register Lisp_Object tem;
    CHECK_SYMBOL (feature, 0);
    tem = Fmemq (feature, Vfeatures);
- 
-   LOADHIST_ATTACH (Fcons (Qrequire, feature));
    
    if (NILP (tem))
      {
        int count = specpdl_ptr - specpdl;
  
        /* Value saved here is to be restored into Vautoload_queue */
        record_unwind_protect (un_autoload, Vautoload_queue);
--- 3076,3087 ----
    register Lisp_Object tem;
    CHECK_SYMBOL (feature, 0);
    tem = Fmemq (feature, Vfeatures);
    
    if (NILP (tem))
      {
        int count = specpdl_ptr - specpdl;
+ 
+       LOADHIST_ATTACH (Fcons (Qrequire, feature));
  
        /* Value saved here is to be restored into Vautoload_queue */
        record_unwind_protect (un_autoload, Vautoload_queue);




reply via email to

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