[Mono-bugs] [Bug 356545] New: AsyncCallback failure on Sun SPARC Solaris 8
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Sun Jan 27 08:03:48 EST 2008
https://bugzilla.novell.com/show_bug.cgi?id=356545
Summary: AsyncCallback failure on Sun SPARC Solaris 8
Product: Mono: Runtime
Version: 1.2.6
Platform: Sparc
OS/Version: Solaris 8
Status: NEW
Severity: Normal
Priority: P5 - None
Component: misc
AssignedTo: mono-bugs at lists.ximian.com
ReportedBy: Yasuaki.Hasegawa at fujixerox.co.jp
QAContact: mono-bugs at lists.ximian.com
CC: Yasuaki.Hasegawa at fujixerox.co.jp
Found By: ---
Created an attachment (id=191938)
--> (https://bugzilla.novell.com/attachment.cgi?id=191938)
Test case
Steps to reproduce the problem:
------------------------------
Test case:
using System;
using System.Net;
using System.Net.Sockets;
public class Test
{
public static void Main(string[] args)
{
IPHostEntry hostAddress = Dns.GetHostEntry("www.amazon.com"); // any
ip-reachable host (ex: "www.amazon.com")
foreach (IPAddress addr in hostAddress.AddressList)
{
System.Console.WriteLine("ip address: " + addr.ToString());
Socket socket = new Socket(AddressFamily.InterNetwork,
SocketType.Stream, ProtocolType.Tcp);
// IPEndPoint endPoint = new IPEndPoint(addr, (int)3306);
IPEndPoint endPoint = new IPEndPoint(addr, (int)80);
IAsyncResult ias = socket.BeginConnect(endPoint, new
AsyncCallback(ConnectSocketCallback), socket);
if (ias.AsyncWaitHandle.WaitOne(10000,false))
{
Console.WriteLine("WaitOne: return TRUE");
}
else
{
Console.WriteLine("WaitOne: return FALSE");
}
System.Console.WriteLine("done.");
}
}
public static void ConnectSocketCallback(IAsyncResult iar)
{
System.Console.WriteLine("socket callback: " + iar);
Socket sock = (Socket)iar.AsyncState;
try
{
sock.EndConnect(iar);
}
catch (Exception e)
{
System.Console.WriteLine("got exception: {0}", e.ToString());
}
}
}
Actual Results:
------------------------------
On Solaris 8 (Sun SPARC):
AsyncCallBack never reached.
The application terminated with the following console output.
$ gmcs socket.cs
$ mono socket.exe
ip address: 72.21.203.1
WaitOne: return FALSE
done.
The string "WaitOne: return FALSE" was displayed ten seconds later.
Expected Results:
------------------------------
On Windows XP Box (Intel Pentium-M):
AsyncCallBack should be reached.
The following were output in the environment of Microsoft Visual C# 2005
Express Edition.
ip address: 72.21.203.1
socket callback: System.Net.Sockets.ConnectAsyncResult
WaitOne: return TRUE
done.
The character string "WaitOne:return TRUE" was displayed soon.
How often does this happen?
------------------------------
Every time.
Additional Information:
------------------------------
(1) Build Date & Platform
# uname -a
SunOS ozone 5.8 Generic_117350-46 sun4u sparc SUNW,Sun-Blade-1000
# gmcs --version
Mono C# compiler version 1.2.6.0
# mono --version
Mono JIT compiler version 1.2.6 (tarball)
Copyright (C) 2002-2007 Novell, Inc and Contributors. www.mono-project.com
TLS: normal
GC: Included Boehm (with typed GC)
SIGSEGV: normal
Notification: Thread + polling
Architecture: sparc
Disabled: none
(2) Related issue report
Bug 319828 - BeginConnect is still broken on OS X, just in a more interesting
way
https://bugzilla.novell.com/show_bug.cgi?id=MONO77020
Bug 320405 - AsyncCallBack failure
https://bugzilla.novell.com/show_bug.cgi?id=320405
--
Configure bugmail: https://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