[netcore] Ongoing work. (#13391)
[mono-project.git] / mono / tests / threadpool-exceptions6.cs
blob5612106d4db1aa11796a93a49dd2223a084d6ea7
1 using System;
2 using System.Threading;
4 class Test {
5 static int Main ()
7 AppDomain.CurrentDomain.UnhandledException += OnUnhandledException;
8 WaitCallback wcb = new WaitCallback ((a) => {
9 Thread.CurrentThread.Abort ();
10 });
11 wcb.BeginInvoke (wcb, null, null);
12 Thread.Sleep (1000);
13 return 0;
16 static void OnUnhandledException (object sender, UnhandledExceptionEventArgs e)
18 Environment.Exit (1);