[Mono-bugs] [Bug 566241] New: Thread.Abort doesn't interrupt tight loop
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Sat Dec 19 04:44:02 EST 2009
http://bugzilla.novell.com/show_bug.cgi?id=566241
http://bugzilla.novell.com/show_bug.cgi?id=566241#c0
Summary: Thread.Abort doesn't interrupt tight loop
Classification: Mono
Product: Mono: Runtime
Version: 2.6.x
Platform: x86
OS/Version: Windows 7
Status: NEW
Severity: Normal
Priority: P5 - None
Component: misc
AssignedTo: mono-bugs at lists.ximian.com
ReportedBy: tomas.matousek at microsoft.com
QAContact: mono-bugs at lists.ximian.com
Found By: ---
Blocker: ---
User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1;
Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729;
Media Center PC 6.0; InfoPath.3; MS-RTC LM 8; MALC)
The following program hangs on Mono. Works on .NET.
----
using System.Threading;
using System;
public class C {
public static void Main() {
var t = new Thread(new ThreadStart(() => {
int i = 0;
while (true) {
i++;
}
}));
t.Start();
while (t.ThreadState != ThreadState.Running) {
Thread.Sleep(100);
}
Console.WriteLine("aborting");
t.Abort();
Console.WriteLine("joining");
t.Join();
Console.WriteLine("joined");
}
}
Reproducible: Always
Steps to Reproduce:
compile and run the above code
Actual Results:
aborting
joining
hang ...
Expected Results:
aborting
joining
joined
--
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the mono-bugs
mailing list