lynx-dev
[Top][All Lists]
Advanced

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

Re: lynx-dev leaks (was: bug: print vs partial)


From: dickey
Subject: Re: lynx-dev leaks (was: bug: print vs partial)
Date: Fri, 4 Dec 1998 06:53:30 -0500 (EST)

> > but as I said 'mostly': LP wanted to apply the fix for UCdomap.c (to 
> > 2.8.1), 
> > (which I found was a permanent leak). 
>  
> Is this a permanent one? 

I'll check (on my list).  When I say "permanent", I'm talking about
memory which is allocated once for convenience, perhaps reallocated
several times during the course of the program - but not normally
freed on exit.  (The C library does this, e.g., for the buffers
associated with stdout).  Lynx is instrumented to do a audit on exit
and report everything that it knows about - but not all items are
meaningful. I agree that it's good to update the instrumentation,
but not to take time for the 2.8.1 bugfixes for those.  After all,
we don't (currently) have someone like TDR spamming the group telling
us about memory leaks he's "discovered".
  
> Memory leak detected. 
> Pointer:        0x8167ac0 
> Contains::      <h1>Lynx (2.8.2dev.8), help on <a href="file://loc 
> ByteSize:       297 
> FileName:       ../../../WWW/Library/Implementation/HTString.c 
> LineCount:      349 
>  
> Simply starting Lynx and viewing the cookie jar page seems to leak about 
> 30k (I have a lot of cookies when I start up). 
>  
>  
> I'm not sure exactly how to go about determining if a leak is permanent or 
> non-permanent, and looking back through the cookie code, the leaks I was 

It takes analysis - I haven't looked closely at these either.  (You can
also be mislead if the instrumentation frees something that you would
expect the application to free normally - so it works both ways).

> thinking of before seem to not be a problem. I think they are simply the 
> domain entries for each domain, which are still used (if I free them, we 
> get empty cookies during runtime). These leaks are: 
>  
> Memory leak detected. 
> Pointer:        0x81589f0 
> Contains::      |||||||||||| 
> ByteSize:       12 
> FileName:       ./LYCookie.c 
> LineCount:      402 
>  
> Memory leak detected. 
> Pointer:        0x8148110 
> Contains::      |||||||||||| 
> ByteSize:       12 
> FileName:       ./LYCookie.c 
> LineCount:      2575 
>  
>  
> Memory leak detected. 
> Pointer:        0x8147bc0 
> Contains::      |||||||||||| 
> ByteSize:       12 
> FileName:       ./LYCookie.c 
> LineCount:      2653 
>  
> Line 2575 and 2653 are mine, from cookie_add_acceptlist and 
> cookie_add_rejectlist. It looks like the cookie data itself is already 
> being properly free'd (is the '|' a NULL in memory?), only the domain_entry 
> struct (which is 12 bytes) seems to be left at exit. It would indeed look 
> cleaner to have this cleaned out, but I don't think it's a problem. 
>  
>  
> Another leak at: 
>  
> Memory leak detected. 
> Pointer:        0x81381e0 
> Contains::      LYNX_VERSION=2.8.2dev.8| 
> ByteSize:       24 
> FileName:       ./LYMain.c 
> LineCount:      754 
> realloced:      ./LYMain.c 
> LineCount:      755 
>  
> --  
> "...and the fully armed nuclear warheads, are, of course, merely a 
> courtesy detail." 


-- 
Thomas E. Dickey
address@hidden
http://www.clark.net/pub/dickey

reply via email to

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