This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Socket read problem on Windows XP Pro & Cygwin


Corinna Vinschen <corinna-cygwin <at> cygwin.com> writes:

> 
> This I can't tell you since I don't know the server side of the
> connection.  It's normal to get EOF (== 0) over and over again if EOF
> has been detected.  This behaviour can be observed on, for instance,
> Linux, too.

Well..I thought it shouldn't if it's set for blocking mode (which is the 
default I think).....but *now* I see why... SEE #3 BELOW:

> 
> FYI, I tried your application against a simple time server, port 37,
> which is known to accept a connection, sends 4 bytes and then closes the
> connection.
> 

Good idea.  FYI, the server program I am trying to run is a virtual serial 
port program at this url:

http://www.hw-group.com/products/hw_vsp/index_en.html

Thanks for the input...and I think I am making headway with this help.  After 
some more testing...I now think the problem has nothing directly to do with 
cygwin or my program.  Here's why:

1.) Using a time server as the server always works...no matter where I run the 
client program.

2.) I now have 2 PC's that fail, and one that doesn't.  If I run the client on 
the PC's that fail, and I run the "hw-group" server program ANYWHERE, the 
client fails to receive data.

3.) If I run some *other* client software on the PC's that fail 
(telnet...hyperterm....etc...) and try to connect to the "hw-group" server (no 
matter where that server is running), that also fails.  Those programs report 
that the server ended the connection.  THAT's why read returns 0...because it 
*thinks* the server closed the connection.

4.) Lastly, all client programs (telnet, my program, hyperterm..etc...) all 
work properly with the "hw-group" server when those programs are run on 
the "working" PC (my laptop).

So...it looks to me like there is some kind of basic incompatibility between 
the "hw-group" server program (no matter where it is run) and the winsock code 
on the client PCs that fail....since the problem seems to affect both windows 
and cygwin clients alike.  Doesn't look like this really has anything to do 
with cygwin.  One of the client PC's that fails is still only SP1 of XP.  The 
other is SP2....maybe I'll try and update the SP1 machine to the latest and 
see what happens.

Thanks for all of your help.  Unfortunately...now the problem isn't really 
directly under my control...hope I can find a solution.

Todd







--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]