|
Boost Users : |
From: Sohail Somani (s.somani_at_[hidden])
Date: 2005-08-26 15:51:59
> -----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.
I understand its not a leak. There should atleast be a comment there
saying we are not going to deallocate this memory that is allocated
once. Its great you know, but part of this thread would have been
avoided had there been that comment.
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