Please do not reply to this email- if you want to comment on the bug, go to the URL shown below and enter your comments there.
Changed by [EMAIL PROTECTED] http://bugzilla.ximian.com/show_bug.cgi?id=80327 --- shadow/80327 2006-12-20 09:59:44.000000000 -0500 +++ shadow/80327.tmp.9204 2006-12-20 09:59:44.000000000 -0500 @@ -0,0 +1,55 @@ +Bug#: 80327 +Product: Mono: Class Libraries +Version: 1.2 +OS: +OS Details: +Status: NEW +Resolution: +Severity: +Priority: Wishlist +Component: CORLIB +AssignedTo: [EMAIL PROTECTED] +ReportedBy: [EMAIL PROTECTED] +QAContact: [EMAIL PROTECTED] +TargetMilestone: --- +URL: +Cc: +Summary: Background thread that won't die + +Steps to reproduce the problem: +Compile and run the attached testcase. "Exiting" is printed, but the +program never exits as the UdpClient is in a blocking receive. + + + +using System.Threading; +using System; +using System.Net.Sockets; +using System.Net; +namespace ConsoleApplication3 +{ + class Program + { + static void Main(string[] args) + { + Thread s = new Thread(new ThreadStart(WontDie)); + s.IsBackground = true; + s.Start(); + System.Threading.Thread.Sleep(1000); + Console.WriteLine("Exiting"); + } + + private static void WontDie() + { + while (true) + { + IPEndPoint endpoint = new +IPEndPoint(IPAddress.Parse("239.255.255.250"), 1900); + UdpClient s = new UdpClient(); + byte[] buffer = new byte[1024]; + s.Send(buffer, buffer.Length, endpoint); + s.Receive(ref endpoint); + } + } + } +} _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
