<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>CLR on Andrew Walsh</title><link>http://awalsh128.com/tags/clr/</link><description>Recent content in CLR on Andrew Walsh</description><generator>Hugo -- gohugo.io</generator><language>en-US</language><copyright>© 2026 Andrew Walsh</copyright><lastBuildDate>Wed, 30 Mar 2016 23:52:15 -0700</lastBuildDate><atom:link href="http://awalsh128.com/tags/clr/feed.xml" rel="self" type="application/rss+xml"/><item><title>PCAP-NG reader for .NET.</title><link>http://awalsh128.com/pcap-ng-reader-for-net/</link><pubDate>Wed, 10 Apr 2013 00:00:00 -0700</pubDate><guid>http://awalsh128.com/pcap-ng-reader-for-net/</guid><description>&lt;h3 class="relative group"&gt;Introduction &amp;amp; Scope&#10; &lt;div id="introduction--scope" class="anchor"&gt;&lt;/div&gt;&#10; &#10; &lt;span&#10; class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;&#10; &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#introduction--scope" aria-label="Anchor"&gt;#&lt;/a&gt;&#10; &lt;/span&gt;&#10; &#10;&lt;/h3&gt;&#10;&lt;p&gt;The PCAP-NG file format is used to store network captured data used by&#10;great programs like &lt;a href="http://www.wireshark.org/download.html" target="_blank" rel="noreferrer"&gt;Wireshark&lt;/a&gt;.&#10;There are several API's available for both&#10;&lt;a href="http://www.tcpdump.org/" target="_blank" rel="noreferrer"&gt;Linux&lt;/a&gt; and &lt;a href="http://www.winpcap.org/" target="_blank" rel="noreferrer"&gt;Windows&lt;/a&gt;&#10;but none that are ported to .NET. I decided to &lt;a href="https://github.com/awalsh128/PcapngFile/" target="_blank" rel="noreferrer"&gt;make&#10;one&lt;/a&gt; for my own use in&#10;building a network traffic replay agent.&lt;/p&gt;</description></item><item><title>Reentrant lock acquires in CLR.</title><link>http://awalsh128.com/reentrant-lock-acquires-in-clr/</link><pubDate>Fri, 29 Jul 2011 00:00:00 -0700</pubDate><guid>http://awalsh128.com/reentrant-lock-acquires-in-clr/</guid><description>&lt;p&gt;I always like when a post gets to the point (especially after searching&#10;in Google). In short, &lt;em&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ms741870.aspx" target="_blank" rel="noreferrer"&gt;if you perform an operation that waits to&#10;acquire a lock, the thread doesn't actually&#10;stop&lt;/a&gt;&lt;/em&gt;.&lt;br&gt;&#10;&lt;br&gt;&#10;In concrete terms of .NET coding, if you call the&#10;&lt;a href="http://msdn.microsoft.com/en-us/library/system.threading.waithandle.waitone.aspx" target="_blank" rel="noreferrer"&gt;WaitOne&lt;/a&gt; method&#10;on a thread, it may still process events that the CLR deems &amp;quot;high&#10;priority&amp;quot;. This can be a big problem if the event handlers go into the&#10;critical region you are trying to protect.&lt;br&gt;&#10;\&lt;/p&gt;</description></item></channel></rss>