<div><blockquote class="gmail_quote" style="margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; margin-left: 0.80ex; border-left-color: #cccccc; border-left-width: 1px; border-left-style: solid; padding-left: 1ex">
Thankyou both Don Stewart and Simon Marlow for your responses.</blockquote><div><br><br>By&nbsp;adding&nbsp;yield&nbsp;and&nbsp;threadDelay&nbsp;in&nbsp;certain&nbsp;spots&nbsp;I&nbsp;have&nbsp;at least&nbsp;prevented<br>some&nbsp;of&nbsp;the&nbsp;threads&nbsp;from&nbsp;being&nbsp;starved&nbsp;of CPU time.<br>
<br>The only issue&nbsp;now&nbsp;is&nbsp;that&nbsp;terminateProcess&nbsp;doesn&#39;t&nbsp;always terminate <br>netstat.exe in the cmd.exe so I don&#39;t get an exit condition.<br></div><br></div><br>