[Mono-bugs] [Bug 423695] New: problem with System.Net.Sockets;

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Fri Sep 5 10:35:00 EDT 2008


https://bugzilla.novell.com/show_bug.cgi?id=423695


           Summary: problem with  System.Net.Sockets;
           Product: Mono: Runtime
           Version: 1.9
          Platform: i386
        OS/Version: Ubuntu
            Status: NEW
          Severity: Major
          Priority: P5 - None
         Component: misc
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: shai.hess at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: DeveloperNet


Description of Problem:

Before I started with Mono, my server ran on Windows XP without any problem.
Even today I have two .Net application, one run Windows XP and the other run
Mono in Linux. Ubuntu.

The problem is that the client successfully write data (len > 0)to the server
and everything is fine. When the client read from the server in Mono again no
exception! only the client read 0 length data (which is invalid). Sometimes
also when I take down the server and immidiatly bring it up and than send write
from the client to the server (which have connectted socket which suppose to be
not operational because the server went down), the server Receive the data
successfully but for the read the client receive length 0!.

This bug is very critical to me and that what stand between me and to make the
mono option for using my product. (WWW.MFNETDISK.COM). You can have there my
NET code. Try to run the PCserver and the PCTool in mono in Linux.

Thanks,
Shai 

The server codes (make it easy to read):
-------------------------------------
using System.Net;
using System.Net.Sockets;
internal   NetworkStream ns ;
internal   Socket newSocket;
int TcpOP()
{
         IAsyncResult ar= ns.BeginRead (this.buff2Receive,this.DataRead,
                           this.Data2Read,null,null);
         waitrc=ar.AsyncWaitHandle.WaitOne(mswaittimenow,false);
         if (waitrc == false)
         {
           EndConnection();
           return -1;
         }
          byteread=ns.EndRead(ar);
          DoOperation();
         IAsyncResult ar= ns.BeginWrite(sendbuff,0,
         datalen,null,null);
           waitrc=ar.AsyncWaitHandle.WaitOne(WMSWAITTIME,false);
           if (waitrc == false)
           {
             EndConnection();
             return -1;
           }
           ns.EndWrite(ar);
           return 0;
}
EndConnection()
{
  this.ns.Close();
  this.newSocket.Close();
}
                        -------------------------------------

When Mono is the server and other computers is the client (I try Mainframe but
it is happened also when using Mono client. 


Steps to reproduce the problem:
1. 
2. 


Actual Results:


Expected Results:


How often does this happen? 

2-3 times every hour.


Additional Information:


-- 
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