Re: memory leaks using the "manage_new_object" return policy...

David Abrahams <[email protected]>
Newsgroups gmane.comp.lib.boost.langbinding
Message-ID <[email protected]>
Kevin Jones <[email protected]> writes:

> Hi,
>
> I am using the manage_new_object return policy to wrap
> "newed" C++ object in an effort to conserve memory.
>
> Even though I am deleting the returned object in
> Python and invoking the Python garbage collector I
> still have a leak. 

Are you sure it's the same object you newed?

> This is a long-running systems
> adminstration app the read the contents of a very
> large database.
>
> Any suggestions on how to make manage_new_object
> behave correctly?

It does behave correctly.

Incidentally, you're on the wrong mailing list for Boost.Python
questions.  Please see
http://www.boost.org/more/mailing_lists.htm#cplussig

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.