The false reporting of memory leaks is a known issue with the Visual Studio debugging environment, and has been discussed on this list many times, as new OSG users discover the error messages. From a previous post pulled randomly from the OSG list archive:
>RE: [osg-news] Large numbers of memory leaks and huge STL overhead > > * This message: [ Message body ] [ More options ] > * Related messages: [ Next message ] [ Previous message ] [ Next in thread ] [ Replies ] > >From: S S E L <SSEL_at_rmcs.cranfield.ac.uk> >Date: Mon Jun 30 2003 - 00:54:10 PDT > >If you trace through the final moments of execution of an OSG program, >you'll discover that the VC++ memory logging occurs prior to any dlls being >unloaded. Objects that are declared static within a dll are destroyed when >the dll is unloaded. However, since this unloading occurs after the memory >check, then objects that have been declared static appear not to be deleted. >For example the osgDB::registry can appear to leak memory in a number of >places. However, if you place a breakpoint in the registry destructor it >does get called and memory allocated is indeed freed as you can readily >trace through the deletion of all of its members. > >Joseph Steel So, don't worry about them. The OSG libraries are about as clean as you will find anywhere. Blake Williams DRS TCS, Inc 651 Anchors Street Fort Walton Beach, FL 32548 (850) 302-3281 Fax: (850) 302-3968 Notice: This is an unofficial communication and is not binding on DRS TCS, Inc. The only authorized representative of DRS TCS, Inc is the Contracts Department. This communication may contain privileged or other DRS TCS, Inc proprietary information. If you are not intended recipient or believe that you have received this communication in error, please reply to the sender indicating that fact and delete the copy you received. In addition, you should not print, retransmit, disseminate, or otherwise use the information. THANK YOU -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Tuesday, October 10, 2006 6:07 AM To: [email protected] Subject: [osg-users] Plumbing problems... Hi Thibault, Thanks for the response, but I confess to being still a little confused. I have debug builds of my ActiveX control, and Debug builds of the OSG libraries. I know the allocation number of a memory block that is leaking, but this is within the OSG world. Do I therefore have to put the CRTAllocbreak (?) command in the OSG libraries ? I suppose I could go to this extreme, however I suppose what I'm looking for is a more general overview of how OSG shuts down. The OSG libraries define a lot of constant strings, and these are certainly being leaked when I'm shutting down my ActiveX control. It also looks as if the Cameras are hanging around too. Evidently I'm OSG is not shutting down properly, and I suppose I was looking for pointers as to how this might be occuring. I'm setting my viewer to NULL after syncing, and the control is being deleted, yet its almost as if the OSG reference structures aren't having their count decremented and then being destroyed. Help! Neil. _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/ _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
