[Mono-bugs] [Bug 623477] New: Different behavior on Thread(ThreadEntryPoint, maxStackSize) on .net and mono
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Mon Jul 19 10:16:53 EDT 2010
http://bugzilla.novell.com/show_bug.cgi?id=623477
http://bugzilla.novell.com/show_bug.cgi?id=623477#c0
Summary: Different behavior on Thread(ThreadEntryPoint,
maxStackSize) on .net and mono
Classification: Mono
Product: Mono: Runtime
Version: SVN
Platform: i386
OS/Version: Linux
Status: NEW
Severity: Minor
Priority: P5 - None
Component: misc
AssignedTo: mono-bugs at lists.ximian.com
ReportedBy: tquerci at gmail.com
QAContact: mono-bugs at lists.ximian.com
Found By: Community User
Blocker: No
Description of the problem:
I'm testing an the behavior of Thread class on mono and VS2005.
In the documentation page of MS it's specify that is maxStackSize is
less of 128KB an ArgumentOutOfRangeException it's raised.
This seems not to be true on .Net environment.
Using the following code I try to change the maxStackSize value and wait to get
the exception.
Seems that using any value between 0 and 262144 (256k) I get the same
behavior on windows.
I suppose that it's better is the behavior it's the same, not if mono
respect the official documentation and .net not :)
===================== TESTING CODE SAMPLE ===============================
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
namespace testThread
{
class Program
{
static void Main(string[] args)
{
Program p = new Program();
Thread t = new Thread(p.ThreadEntryPoint, Int32.Parse(args[0]));
t.Start();
Console.WriteLine("T0 - Chk1");
Thread.Sleep(5000);
Console.WriteLine("T0 - Exit");
}
public void ThreadEntryPoint(Object obj)
{
int i;
if (obj == null)
{
Console.WriteLine("T1 - Chk1");
i = 32000;
}
else
{
i = (int)obj - 1;
}
if (i > 0)
{
Console.WriteLine("I=" + i);
ThreadEntryPoint(i);
}
else
{
Console.WriteLine("T1 - Exit");
}
}
}
}
--
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