Boost logo

Boost Users :

From: Elisha Berns (e.berns_at_[hidden])
Date: 2005-08-26 16:15:42


Well, since I started this whole thing, I have to ask... If it's a
singleton, doesn't it need to clean itself up? If the assumption is
that the OS will clean it up when the process is killed, isn't that a
bit shaky as far as sound assumptions go?

Elisha

> -----Original Message-----
> From: boost-users-bounces_at_[hidden] [mailto:boost-users-
> bounces_at_[hidden]] On Behalf Of Peter Dimov
> Sent: Friday, August 26, 2005 1:45 PM
> To: boost-users_at_[hidden]
> Subject: Re: [Boost-users] Boost.Thread memory leak reported
>
> Sohail Somani wrote:
>
> >>> Any dynamically allocated memory that isn't freed is a Bad
> >> Thing imho.
> >>
> >> Because?
> >
> > Was it forgotten? Was it intentional? If the assumption is it will
> > always be freed, then there is no ambiguity.
>
> Seems clearly intentional to me - the allocation is invoked by
call_once
> and
> is a textbook implementation of a thread safe singleton. A "this is
not a
> leak" comment may help.
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net