3 using System
.Threading
;
6 public static void Main() {
7 Thread thr
=new Thread(new ThreadStart(foo
.thread
));
10 Console
.WriteLine("Aborting child thread");
12 Console
.WriteLine("Main thread returns");
15 public static void thread() {
17 Console
.WriteLine("Thread running");
19 } catch(ThreadAbortException
) {
21 Console
.WriteLine("Abort reset!");
23 Console
.WriteLine("ThreadAbortException finally");
26 Console
.WriteLine("Thread running");
28 } catch(ThreadAbortException
) {
30 Console
.WriteLine("Abort reset!");
32 Console
.WriteLine("ThreadAbortException finally");
35 Console
.WriteLine("Thread running");
37 } catch(ThreadAbortException
) {
39 Console
.WriteLine("Abort reset!");
41 Console
.WriteLine("ThreadAbortException finally");
44 Console
.WriteLine("Thread running");
46 } catch(ThreadAbortException
) {
48 Console
.WriteLine("Abort reset!");
50 Console
.WriteLine("ThreadAbortException finally");
53 Console
.WriteLine("Thread running");
54 } catch(ThreadAbortException
) {
56 Console
.WriteLine("Abort reset!");
58 Console
.WriteLine("ThreadAbortException finally");