[vtkusers] vtkMFC memory leaking

David Cole david.cole at kitware.com
Thu Mar 6 06:45:15 EST 2008


Please mail your replies to the VTK mailing list as well... Perhaps somebody
else will benefit from this information or be able to answer your question
more clearly...


On 3/6/08, Hochan Kim <hckim at andong.ac.kr> wrote:
>
>  I built the VTK/Examples/GUI/Win32/vtkMFC/vtkSDI. And the VTK version is
> 5.0.3.
>
> Before receiving your reply, I changed the vtk installation to static
> library from shared one by OFF the BUILD_SHARED_LIBS at cmake. And it does
> not make memory leaks.
>
> So the problem is strongly concerned with DLL as you mentioned. But I
> don't know how to fixing the CVS HEAD. Actually I didn't have any experience
> with CVS. Can I fix the problem with changing project setting within the
> Visual C++?
>
> Thank you.
>
> Hochan
>
>
>
>
> ---------------------------------------------------------------------------------------
>
>     Hochan Kim    Ph. D.
>
>     ssistant professor,                           hckim at andong.ac.kr
>
>
>     School of Mechanical Engineering, Andong National University
>
>     388 Song-chon Dong, Andong, Kyoung-buk, 760-749, South Korea
>
>     Tel: +82-54-820-5269                          Fax: +82-54-820-5044
>
>
> ---------------------------------------------------------------------------------------
>
>
>
> *From:* David Cole [mailto:david.cole at kitware.com]
> *Sent:* Tuesday, March 04, 2008 10:08 PM
> *To:* Hochan Kim
> *Cc:* vtkusers at vtk.org
> *Subject:* Re: [vtkusers] vtkMFC memory leaking
>
>
>
> Which executable did you build?
>
> VTK/Examples/GUI/Win32/vtkMFC/vtkMDI or something else?
>
> What version of VTK are you using? The MFC mem leak problem is usually a
> "false alarm" in VTK-5-0 caused by the ordering of loading of VTK dlls. It
> should be fixed in the CVS HEAD build of VTK because we added code to delay
> load the VTK dlls, thereby ensuring that they are unloaded *before* the MFC
> dlls and then the MFC dlls can do their mem leak analysis correctly.
>
>
> HTH,
> David
>
>
>
>  On 3/4/08, *Hochan Kim* <hckim at andong.ac.kr> wrote:
>
> Hi. Everybody!
>
> I build the example project vtkMFC, but when executed with debug mode it
> generates a lot of memory leak.
>
> I'm using VS2005 with winXP. If you know anything about the problem please
> tell me whatever.
>
> Thanks!
>
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20080306/19e36920/attachment.htm>


More information about the vtkusers mailing list