<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="https://syndication.webwiz.net/rss_namespace/">
 <channel>
  <title>Codejock Developer Community : CXTPCommandBarsSiteBase memory leak</title>
  <link>http://forum.codejock.com/</link>
  <description><![CDATA[This is an XML content feed of; Codejock Developer Community : Command Bars : CXTPCommandBarsSiteBase memory leak]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Fri, 15 May 2026 09:45:31 +0000</pubDate>
  <lastBuildDate>Sun, 18 Oct 2009 04:42:58 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 12.04</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>forum.codejock.com/RSS_post_feed.asp?TID=15381</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Codejock Developer Community]]></title>
   <url>http://forum.codejock.com/forum_images/codejock-logo.gif</url>
   <link>http://forum.codejock.com/</link>
  </image>
  <item>
   <title><![CDATA[CXTPCommandBarsSiteBase memory leak : Excellent ]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53978&amp;title=cxtpcommandbarssitebase-memory-leak#53978</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2928">terrym</a><br /><strong>Subject:</strong> 15381<br /><strong>Posted:</strong> 18 October 2009 at 4:42am<br /><br />Excellent]]>
   </description>
   <pubDate>Sun, 18 Oct 2009 04:42:58 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53978&amp;title=cxtpcommandbarssitebase-memory-leak#53978</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPCommandBarsSiteBase memory leak : yes, sure. ]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53976&amp;title=cxtpcommandbarssitebase-memory-leak#53976</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 15381<br /><strong>Posted:</strong> 18 October 2009 at 1:27am<br /><br />yes, sure.]]>
   </description>
   <pubDate>Sun, 18 Oct 2009 01:27:26 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53976&amp;title=cxtpcommandbarssitebase-memory-leak#53976</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPCommandBarsSiteBase memory leak : Did this make fix for 13.2?  ]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53928&amp;title=cxtpcommandbarssitebase-memory-leak#53928</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2928">terrym</a><br /><strong>Subject:</strong> 15381<br /><strong>Posted:</strong> 16 October 2009 at 7:50am<br /><br />Did this make fix for 13.2?<DIV></DIV>]]>
   </description>
   <pubDate>Fri, 16 Oct 2009 07:50:56 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53928&amp;title=cxtpcommandbarssitebase-memory-leak#53928</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPCommandBarsSiteBase memory leak : Hi,  Thanks, indeed we didn&amp;#039;t...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53916&amp;title=cxtpcommandbarssitebase-memory-leak#53916</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=6851">Oleg</a><br /><strong>Subject:</strong> 15381<br /><strong>Posted:</strong> 16 October 2009 at 5:23am<br /><br />Hi,<DIV>&nbsp;</DIV><DIV>Thanks, indeed we didn't catch such scenario. I will add same fix code.</DIV><DIV><BR>Thanks.</DIV>]]>
   </description>
   <pubDate>Fri, 16 Oct 2009 05:23:33 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53916&amp;title=cxtpcommandbarssitebase-memory-leak#53916</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPCommandBarsSiteBase memory leak : Hmmm, why not destroy the command-bar...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53915&amp;title=cxtpcommandbarssitebase-memory-leak#53915</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2198">znakeeye</a><br /><strong>Subject:</strong> 15381<br /><strong>Posted:</strong> 16 October 2009 at 5:07am<br /><br />Hmmm, why not destroy the command-bar in OnDestroy()?]]>
   </description>
   <pubDate>Fri, 16 Oct 2009 05:07:04 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53915&amp;title=cxtpcommandbarssitebase-memory-leak#53915</guid>
  </item> 
  <item>
   <title><![CDATA[CXTPCommandBarsSiteBase memory leak :  XTP 12.0.1, but I think this...]]></title>
   <link>http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53913&amp;title=cxtpcommandbarssitebase-memory-leak#53913</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://forum.codejock.com/member_profile.asp?PF=2198">znakeeye</a><br /><strong>Subject:</strong> 15381<br /><strong>Posted:</strong> 16 October 2009 at 5:04am<br /><br /><FONT color=#0000ff size=2><FONT color=#0000ff size=2><DIV><FONT color=#000000>XTP 12.0.1, but I think this is present in all versions.</FONT></DIV><DIV>&nbsp;</DIV><DIV>class</FONT></FONT><FONT size=2> </FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>CMyPane</FONT></FONT><FONT size=2> : </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>public</FONT></FONT><FONT size=2> </FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>CXTPFrameWndBase</FONT></FONT><FONT size=2>&lt;</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>CWnd</FONT></FONT><FONT size=2>&gt;</FONT></DIV><DIV><FONT size=2>...</FONT></DIV><DIV><FONT size=2><FONT color=#0000ff size=2><FONT color=#0000ff size=2>int</FONT></FONT><FONT size=2> </FONT><FONT color=#010001 size=2><FONT color=#000000 size=2>CMyPane</FONT></FONT><FONT size=2>::</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>OnCreate</FONT></FONT><FONT size=2>(</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>LPCREATESTRUCT</FONT></FONT><FONT size=2> </FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>lpCreateStruct</FONT></FONT><FONT size=2>)</FONT></FONT></DIV><DIV><FONT size=2><FONT size=2>{</FONT></FONT></DIV><DIV><FONT size=2>&nbsp;&nbsp;&nbsp; <FONT color=#0000ff size=2><FONT color=#0000ff size=2>if</FONT></FONT><FONT size=2> (</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>CXTPFrameWndBase</FONT></FONT><FONT size=2>&lt;</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>CWnd</FONT></FONT><FONT size=2>&gt;::</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>OnCreate</FONT></FONT><FONT size=2>(</FONT><FONT color=#010001 size=2><FONT color=#010001 size=2>lpCreateStruct</FONT></FONT><FONT size=2>) == -1)</FONT></FONT></DIV><DIV><FONT size=2>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT color=#0000ff size=2><FONT color=#0000ff size=2>return</FONT></FONT><FONT size=2> -1;</DIV><DIV><P></FONT><FONT color=#010001 size=2><FONT color=#010001 size=2></P><DIV>&nbsp;&nbsp;&nbsp; <strong>InitCommandBars</strong></FONT></FONT><FONT size=2><strong>();</strong></DIV><DIV></DIV><DIV></DIV><DIV></DIV><DIV>&nbsp;&nbsp;&nbsp; ...</DIV><DIV>}</DIV><DIV>&nbsp;</DIV><DIV>In my application this window is created, destroyed and then created again - without destroying the CMyPane-object:</DIV><DIV>&nbsp;</DIV><DIV>m_myPane.Destroy();</DIV><DIV>...</DIV><DIV>m_myPane.Create(...); // MEMORY LEAK!</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV><DIV>The error lies in XTPFrameWnd.h. Obviously, you don't think about the above scenario!</DIV><DIV>virtual BOOL InitCommandBars(CRuntimeClass* pCommandBarsClass = RUNTIME_CLASS(CXTPCommandBars))<BR>&nbsp;{</DIV><DIV>&nbsp;&nbsp;&nbsp; <FONT color=#ff0000>// Begin FIX</FONT></DIV><DIV><FONT color=#ff0000>&nbsp;&nbsp;&nbsp; if (m_pCommandBars)<BR>&nbsp;&nbsp;&nbsp; {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; m_pCommandBars-&gt;InternalRelease();<BR>&nbsp;&nbsp;&nbsp; }</FONT></DIV><DIV><FONT color=#ff0000>&nbsp;&nbsp;&nbsp; // End&nbsp;FIX<BR></FONT>&nbsp;&nbsp;&nbsp; ASSERT(pCommandBarsClass-&gt;IsDerivedFrom(RUNTIME_CLASS(CXTPCommandBars)));<BR><strong>&nbsp;&nbsp;&nbsp; m_pCommandBars =&nbsp; (CXTPCommandBars*) pCommandBarsClass-&gt;CreateObject();<BR></strong>&nbsp;&nbsp;&nbsp;&nbsp;ASSERT(m_pCommandBars);<BR>&nbsp;&nbsp;&nbsp;&nbsp;if (!m_pCommandBars)<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return FALSE;<BR>&nbsp;&nbsp;&nbsp; m_pCommandBars-&gt;SetSite(this);<BR>&nbsp;&nbsp;&nbsp; m_pCommandBars-&gt;EnableDocking();<BR>&nbsp;&nbsp;&nbsp; return TRUE;<BR>}</DIV></FONT></DIV></FONT>]]>
   </description>
   <pubDate>Fri, 16 Oct 2009 05:04:09 +0000</pubDate>
   <guid isPermaLink="true">http://forum.codejock.com/forum_posts.asp?TID=15381&amp;PID=53913&amp;title=cxtpcommandbarssitebase-memory-leak#53913</guid>
  </item> 
 </channel>
</rss>