Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Controls
  New Posts New Posts RSS Feed - CXTTabView Destructor Heap Corruption
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTTabView Destructor Heap Corruption

 Post Reply Post Reply
Author
Message
tommyvee View Drop Down
Groupie
Groupie


Joined: 21 August 2007
Location: United States
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote tommyvee Quote  Post ReplyReply Direct Link To This Post Topic: CXTTabView Destructor Heap Corruption
    Posted: 04 October 2010 at 1:04am
I have an application with CXTTabView that pops up a window with a "Heap corruption" warning while working through the windows functions after calling the CXTTabView destructor, when exiting from the application.

This error occurs in wincore.cpp  at line 1033 (Visual Studio 2010 on W7), which is the line
bResult = ::DestroyWindow(m_hWnd) 
below. At this time, the debugger gives ??? for m_hWnd and for m_pCtrlSite.


Here is a cut and paste from wincore.cpp showing where the error occurs.

 #ifdef _AFX_NO_OCC_SUPPORT
if (m_hWnd != NULL)
bResult = ::DestroyWindow(m_hWnd);
#else //_AFX_NO_OCC_SUPPORT
if ((m_hWnd != NULL) || (m_pCtrlSite != NULL))
{
if (m_pCtrlSite == NULL)
bResult = ::DestroyWindow(m_hWnd);
else
bResult = m_pCtrlSite->DestroyControl();
}
#endif //_AFX_NO_OCC_SUPPORT

Does anyone have an idea of what might be causing this?
Ideas about how to do additional debugging are also welcome.

Thanks,
Tom
Back to Top
tommyvee View Drop Down
Groupie
Groupie


Joined: 21 August 2007
Location: United States
Status: Offline
Points: 11
Post Options Post Options   Thanks (0) Thanks(0)   Quote tommyvee Quote  Post ReplyReply Direct Link To This Post Posted: 05 October 2010 at 7:48pm
I did more testing and the heap corruption occurs when I attach a CTreeView-derived class to a CXTPDockingPane pane, so I will start a new topic in the DockingPane forum asking what about attaching a view might cause heap corruption.
Thanks in advance for any suggestions,
Tom
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.172 seconds.