<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>.NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx</link><description>I was looking at a memory dump recently for an issue where the process would grow to over 1 GB and return OutOfMemory Exceptions. Debugging the issue: A full user dump of the w3wp.exe process was taken with debug diag 1.1 when memory was really high.</description><dc:language>sv-SE</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Anith &amp;raquo; .NET Memory Leak: To dispose or not to dispose, that???s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9393155</link><pubDate>Tue, 03 Feb 2009 15:50:13 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9393155</guid><dc:creator>Anith &amp;raquo; .NET Memory Leak: To dispose or not to dispose, that???s the 1 GB question</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://www.anith.com/?p=4911"&gt;http://www.anith.com/?p=4911&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>Listen up! GDI+ Dispose</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9393184</link><pubDate>Tue, 03 Feb 2009 16:22:14 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9393184</guid><dc:creator>No1 Microsoft Fan</dc:creator><description>&lt;p&gt;Note: Thanks Tess! ;-) &amp;amp;#160; .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question&lt;/p&gt;
</description></item><item><title>.NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9393637</link><pubDate>Tue, 03 Feb 2009 22:39:13 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9393637</guid><dc:creator>What's New</dc:creator><description>&lt;p&gt;I was looking at a memory dump recently for an issue where the process would grow to over 1 GB and return&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9393639</link><pubDate>Tue, 03 Feb 2009 22:39:33 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9393639</guid><dc:creator>Viking</dc:creator><description>&lt;p&gt;Stumbled over this blog a few days ago and I'm amazed of how good it is. I love the examples you are using and hope to be able to go through all the labs in the very near future. &lt;/p&gt;
&lt;p&gt;Keep up the good work!!!!&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9394127</link><pubDate>Wed, 04 Feb 2009 04:12:38 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9394127</guid><dc:creator>barrkel</dc:creator><description>&lt;p&gt;What .NET drawing namespace *should* be used for creating and processing images in an ASP.NET application?&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9394423</link><pubDate>Wed, 04 Feb 2009 06:39:24 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9394423</guid><dc:creator>Shivam</dc:creator><description>&lt;p&gt;Great post as usual. Since I discovered the work of debugging I have been actively doing memory dumps of all the applications I have worked on. Thanks for the great insight in the debugging world , now windbg is my best friend :)&lt;/p&gt;
&lt;p&gt;Regards&lt;/p&gt;
&lt;p&gt;Shivam&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9394638</link><pubDate>Wed, 04 Feb 2009 08:10:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9394638</guid><dc:creator>Vesta</dc:creator><description>&lt;p&gt;thanks.it is a good pattern to dispose com objects!&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9394695</link><pubDate>Wed, 04 Feb 2009 08:33:46 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9394695</guid><dc:creator>Thanigainathan.S</dc:creator><description>&lt;p&gt;Hi Tess,&lt;/p&gt;
&lt;p&gt;Do we have any tools like code analysis and telling whatever area where the dispose is not done well ?&lt;/p&gt;
&lt;p&gt;That will be of great help. Or Microsoft can add this feature in VS2008 code analysis feature.&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Thani&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9394905</link><pubDate>Wed, 04 Feb 2009 10:36:37 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9394905</guid><dc:creator>Tess</dc:creator><description>&lt;p&gt;Barrkel, &amp;nbsp;unfortunately there are no .net drawing namespaces that are supported for image editing in asp.net or other services. &amp;nbsp; &lt;/p&gt;
&lt;p&gt;That doesn't mean that you can't use them, it just means that if you run into issues there will be no fixes etc. &amp;nbsp;unless you can repro the issue in a winforms app. It also means that they are often inappropriate to use in service applications for the reasons mentioned above (user context, desktop heap exhaustion etc.)&lt;/p&gt;
&lt;p&gt;I think there might be some 3rd party components though, and for graphing I believe there is now also an MS graph control.&lt;/p&gt;
&lt;p&gt;Thanigainathan, &amp;nbsp;not sure if fxcop will do this, but in esscence it's a bit hard to check as it is only at runtime you will know if it is disposed correctly or not, given that the scope of an object may be very long.&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9395408</link><pubDate>Wed, 04 Feb 2009 14:23:42 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9395408</guid><dc:creator>Jay Adair</dc:creator><description>&lt;p&gt;Great post, thanks Tess.&lt;/p&gt;
&lt;p&gt;One thing though, we're doing a LOT of heavy bitmap work in one of our websites, motoprofessional.com, and have had no problems yet. Though we do take particular care over disposal and resource usage. I didn't know it wasn't recommended for ASP.net apps, nice to know :)&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9396082</link><pubDate>Wed, 04 Feb 2009 19:35:32 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9396082</guid><dc:creator>Dan</dc:creator><description>&lt;p&gt;There's an alternative to !locks for determining what thread currently owns the critical section that your focus thread is waiting on. The critical section is the first parameter passed to ntdll!RtlEnterCriticalSection, so if you dump out the parameters:&lt;/p&gt;
&lt;p&gt;0:061&amp;gt; kb 20&lt;/p&gt;
&lt;p&gt;ChildEBP RetAddr &amp;nbsp;Args to Child &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/p&gt;
&lt;p&gt;2d90b81c 7c822124 7c83970f 0000200c 00000000 ntdll!KiFastSystemCallRet&lt;/p&gt;
&lt;p&gt;2d90b820 7c83970f 0000200c 00000000 00000000 ntdll!NtWaitForSingleObject+0xc&lt;/p&gt;
&lt;p&gt;2d90b85c 7c839620 00000000 00000002 35255d10 ntdll!RtlpWaitOnCriticalSection+0x19c&lt;/p&gt;
&lt;p&gt;2d90b87c 03e6507b 2954eff8 2d90b954 2954eff8 ntdll!RtlEnterCriticalSection+0xa8&lt;/p&gt;
&lt;p&gt;you can use the first parameter as the address to examine the critical section itself:&lt;/p&gt;
&lt;p&gt; 0:061&amp;gt; dt _RTL_CRITICAL_SECTION 2954eff8 &lt;/p&gt;
&lt;p&gt;mymodule!_RTL_CRITICAL_SECTION&lt;/p&gt;
&lt;p&gt; &amp;nbsp; +0x000 DebugInfo &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;: 0x097fde98 _RTL_CRITICAL_SECTION_DEBUG&lt;/p&gt;
&lt;p&gt; &amp;nbsp; +0x004 LockCount &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;: -6&lt;/p&gt;
&lt;p&gt; &amp;nbsp; +0x008 RecursionCount &amp;nbsp; : 1&lt;/p&gt;
&lt;p&gt; &amp;nbsp; +0x00c OwningThread &amp;nbsp; &amp;nbsp; : 0x00000248 &lt;/p&gt;
&lt;p&gt; &amp;nbsp; +0x010 LockSemaphore &amp;nbsp; &amp;nbsp;: 0x0000200c &lt;/p&gt;
&lt;p&gt; &amp;nbsp; +0x014 SpinCount &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;: 0&lt;/p&gt;
&lt;p&gt;The &amp;quot;OwningThread&amp;quot; field stores the thread ID of the owning thread.&lt;/p&gt;
&lt;p&gt;I've found this approach to be quicker than using !locks if all I care about is who owns the CS.&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9396115</link><pubDate>Wed, 04 Feb 2009 19:49:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9396115</guid><dc:creator>duditz</dc:creator><description>&lt;p&gt;Wow, another great and practical tutorial, thanks!&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9396148</link><pubDate>Wed, 04 Feb 2009 20:08:32 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9396148</guid><dc:creator>RussellH</dc:creator><description>&lt;p&gt;In general, if I can't find any documentation on whether a .net object needs to be disposed, by default I will call dispose when I'm finished with it (using using() when possible). &amp;nbsp;So isn't &amp;quot;yes&amp;quot; the broader answer to your question. &amp;nbsp;I mean are there situations where you don't want to call dispose on IDisposable object, even if you're not sure that the object uses pointers to native resources?&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9397790</link><pubDate>Thu, 05 Feb 2009 10:40:20 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9397790</guid><dc:creator>Tess</dc:creator><description>&lt;p&gt;good point Dan, &amp;nbsp;you can actually use sieextpub and run !critlist as well. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;Russel, &amp;nbsp;I can't think of a place where it would be negative to run dispose, so yeah I would agree with you. &amp;nbsp; &amp;nbsp;&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9398318</link><pubDate>Thu, 05 Feb 2009 15:29:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9398318</guid><dc:creator>Adelle</dc:creator><description>&lt;p&gt;When to dispose: always.&lt;/p&gt;
&lt;p&gt;You can try to get by with only disposing when you *know* that native resources are involved, but in doing so, your client code knows something about how the object is implemented. &amp;nbsp;Suppose you swap out a completely managed class that uses no native resources for one which does use native resources - if you weren't previously disposing that object, then now you have to.&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9399854</link><pubDate>Fri, 06 Feb 2009 00:19:48 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9399854</guid><dc:creator>eff Five</dc:creator><description>&lt;p&gt;Adelle&lt;/p&gt;
&lt;p&gt;I don’t think “always” is quite right. If that was the case then there would be no need to even have IDisposable in the first place. The framework would just do it for you when the object was first collected. &lt;/p&gt;
&lt;p&gt;The real answer is you should call dispose when you know you’re done with the object. This because unlike managed resources which are owned by the framework, unmanaged resources still have a memory ownership issue. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;Eric Lippert’s post shows an example of this. &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/ericlippert/archive/2008/09/08/high-maintenance.aspx"&gt;http://blogs.msdn.com/ericlippert/archive/2008/09/08/high-maintenance.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;In the first method there’s no dispose because it doesn’t know that the caller is done with the StreamReader&lt;/p&gt;
&lt;p&gt;public static class StreamReaderExtensions&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;public static IEnumerable&amp;lt;string&amp;gt; Lines(this StreamReader reader)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if (reader== null)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;throw new ArgumentNullException(&amp;quot;reader&amp;quot;);&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;reader.BaseStream.Seek(0, SeekOrigin.Begin);&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;string line;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;while ((line = reader.ReadLine()) != null)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;yield return line;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt;In the second one he can because his method was the one that created the reader&lt;/p&gt;
&lt;p&gt;public static class FileUtilities&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;public static IEnumerable&amp;lt;string&amp;gt; Lines(string filename)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if (filename == null)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;throw new ArgumentNullException(&amp;quot;filename&amp;quot;);&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;return LinesCore(filename);&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;private static IEnumerable&amp;lt;string&amp;gt; LinesCore(string filename)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Debug.Assert(filename != null);&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;using(var reader = new StreamReader(filename))&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;while (true)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{ &lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;string line = reader.ReadLine();&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if (line == null) &lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; yield break;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;yield return line;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9401500</link><pubDate>Fri, 06 Feb 2009 11:47:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9401500</guid><dc:creator>AtulGupta</dc:creator><description>&lt;p&gt;Tess, great blog. &amp;nbsp;I have been following your blogs regularly and find them very informative. &lt;/p&gt;
&lt;p&gt;A question here - usually in dispose, we do call GC.SuppressFinalize(this) and that ensures that finalizer is not required. So if someone in a freak cases misses doing a suppressfinalize, the object will still get into finalize queue, right? &lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9401520</link><pubDate>Fri, 06 Feb 2009 11:55:47 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9401520</guid><dc:creator>Tess</dc:creator><description>&lt;p&gt;Yes AtulGupta, thats correct&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9402832</link><pubDate>Fri, 06 Feb 2009 23:39:49 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9402832</guid><dc:creator>Sean</dc:creator><description>&lt;p&gt;I trying this on my own process (and Notepad.exe just to make sure) and the Memory Pressure Analyzers - MemoryAnalysis.asp ends with:&lt;/p&gt;
&lt;p&gt;MemoryAnalysis.asp Failed 0x800a0006 Microsoft VBScript runtime error Overflow Line 2397, Column 0&lt;/p&gt;
&lt;p&gt;Any ideas what is causing this? &amp;nbsp;I'm using version 1.1 of Debug Diag from the link in this post.&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9402872</link><pubDate>Sat, 07 Feb 2009 00:17:36 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9402872</guid><dc:creator>Alen</dc:creator><description>&lt;p&gt;Very detailed post, thanks Tess! &amp;nbsp;I recently blogged about a situation of resource leaks here: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://kloctalk.klocwork.com/?p=36"&gt;http://kloctalk.klocwork.com/?p=36&lt;/a&gt; &lt;/p&gt;
</description></item><item><title>Links 2009-02-07</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9404600</link><pubDate>Sat, 07 Feb 2009 16:42:48 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9404600</guid><dc:creator>Gunnar Peipman's ASP.NET blog</dc:creator><description>&lt;p&gt;SharePoint Installing a Language Pack for MOSS Mauro Cardarelli writes about how to install language&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9406146</link><pubDate>Sun, 08 Feb 2009 04:47:09 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9406146</guid><dc:creator>Yuri</dc:creator><description>&lt;p&gt;Thanks a lot for your wonderful blog. It is a real lifesaver. &lt;/p&gt;
</description></item><item><title>Interesting Finds: 2009.02.08</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9406220</link><pubDate>Sun, 08 Feb 2009 05:36:40 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9406220</guid><dc:creator>gOODiDEA.NET</dc:creator><description>&lt;p&gt;.NET Proactor Pattern - an asynchronous event handling pattern Step-by-step Introduction to Delegates&lt;/p&gt;
</description></item><item><title>Interesting Finds: 2009.02.08</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9406225</link><pubDate>Sun, 08 Feb 2009 05:37:49 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9406225</guid><dc:creator>gOODiDEA</dc:creator><description>&lt;p&gt;.NETProactorPattern-anasynchronouseventhandlingpatternStep-by-stepIntroductiontoD...&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9413960</link><pubDate>Thu, 12 Feb 2009 06:05:26 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9413960</guid><dc:creator>Andreas Grabner</dc:creator><description>&lt;p&gt;Hi Tess&lt;/p&gt;
&lt;p&gt;Thanks for the detailed explaination. I just published a blog entry about Memory Diagnostics in .NET on the example of SharePoint. As with your example of the System.Drawing objects - SharePoint provides several classes that hold references to native objects. Those objects need to be disposed &amp;quot;manually&amp;quot; in order to be freed by the GC.&lt;/p&gt;
&lt;p&gt;I am using dynaTrace (www.dynatrace.com) for Memory Diagnostics. Most of your desribed steps are automated by dynaTrace and its easy to identify leaks like this.&lt;/p&gt;
&lt;p&gt;Here is the link to the blog-entry: &lt;a rel="nofollow" target="_new" href="http://blog.dynatrace.com/2009/02/12/sharepoint-identifying-memory-problems-introduced-by-custom-code/"&gt;http://blog.dynatrace.com/2009/02/12/sharepoint-identifying-memory-problems-introduced-by-custom-code/&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9427995</link><pubDate>Tue, 17 Feb 2009 20:34:38 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9427995</guid><dc:creator>Scott Walker</dc:creator><description>&lt;p&gt;This question is not strictly related to this post, but since this is the only way to contact you I thought I'd ask here...&lt;/p&gt;
&lt;p&gt;Is it possible using symbol store with source indexed pdb files for managed code to get WinDBG to display the source as you step through the debugger? &amp;nbsp;I've been futzing with this scenario for a while and I'm guessing it is not possible currently, but thought I'd ask the expert! &amp;nbsp;&lt;/p&gt;</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9428540</link><pubDate>Tue, 17 Feb 2009 23:51:58 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9428540</guid><dc:creator>Tess</dc:creator><description>&lt;p&gt;nope, &amp;nbsp;as of now there is no way to step through managed code in windbg (with source code).&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9517107</link><pubDate>Sun, 29 Mar 2009 16:04:37 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9517107</guid><dc:creator>Leo Davidson</dc:creator><description>&lt;p&gt;Sean wrote:&lt;/p&gt;
&lt;p&gt;&amp;quot;MemoryAnalysis.asp Failed 0x800a0006 Microsoft VBScript runtime error Overflow Line 2397, Column 0&amp;quot;&lt;/p&gt;
&lt;p&gt;I ran into the same problem. There's a divide-by-zero error in the ASP/VBScript code when a heap in the target process doesn't reserve any memory.&lt;/p&gt;
&lt;p&gt;It's easy to fix and I've put a corrected version online here:&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://www.pretentiousname.com/debugdiag_fix/"&gt;http://www.pretentiousname.com/debugdiag_fix/&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>Debug Diag script for troubleshooting .NET 2.0 Memory leaks</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9606673</link><pubDate>Tue, 12 May 2009 12:59:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9606673</guid><dc:creator>If broken it is, fix it you should</dc:creator><description>&lt;p&gt;I have put together a quick and dirty debug diag script for troubleshooting .net memory leaks. (attached&lt;/p&gt;
</description></item><item><title>re: .NET Memory Leak: To dispose or not to dispose, that’s the 1 GB question</title><link>http://blogs.msdn.com/tess/archive/2009/02/03/net-memory-leak-to-dispose-or-not-to-dispose-that-s-the-1-gb-question.aspx#9641452</link><pubDate>Tue, 26 May 2009 16:55:02 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9641452</guid><dc:creator>Michal</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I am getting the following error when running the Memory pressure Analysis:&lt;/p&gt;
&lt;p&gt;MemoryAnalysis.asp Failed 0x800a0006 Microsoft VBScript runtime error Overflow: 'Seconds' Line 32, &amp;nbsp;Column 4&lt;/p&gt;
&lt;p&gt;I tried the fix mentioned above and it did not help.&lt;/p&gt;
&lt;p&gt;Any ideas?&lt;/p&gt;
</description></item></channel></rss>