logging-log4cxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Curt Arnold <carn...@houston.rr.com>
Subject Timezone side effects (was Re: Memory Leaks in Log4cxx)
Date Tue, 27 Jul 2004 15:13:41 GMT

On Jul 27, 2004, at 7:29 AM, FabijanicA@nucorsteel.com wrote:
> There are 13 memory leaks and 7 resource leaks reported at the end of
> execution. I am still trying to figure out most of them, but here's 
> where
> some of the leaks reported are coming from:
>
> timezone.cpp      line 32 [2 leaks - calling tzset and gmtime]:
> TimeZonePtr TimeZone::defaultTimeZone = new TimeZone(_T(""));
> timezone.cpp      line 92 [1 leak - calling putenv]:              
> return
> new TimeZone(ID);
>
> tzset(), gmtime() and putenv are all calling malloc()
>


I had been troubled by timezone.cpp, but have not had time to 
investigate the issue.  It appears that it could have unintended side 
effects since it appears to be setting the current timezone not just 
for the logging code but for the application as a whole.


Mime
View raw message