public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Tim Newsham <newsham@aloha.net>
To: gnu-win32@cygnus.com
Subject: corruption in socket layer?
Date: Mon, 06 Oct 1997 14:47:00 -0000	[thread overview]
Message-ID: <199710062146.LAA18698@haleakala.aloha.net> (raw)

Hi,

    I occasionally observe some very strange behaviour in
the socket code.  It seems to me that there is corruption
going on somewhere.  I'm not sure if its cygwin's problem
or winsock's problem.

What I'm seeing is the tcp/ip stack behave improperly at
times.  For example sometimes a close() happens and not
FIN is sent out.  Instead the connection is silently placed
into the closed state.  On the next incoming packet from
the remote, the local TCP stack sends out an RST.

It also appears that I sometimes get an EOF indication
(read returns zero) when the remote side has not closed
the connection, and I have not explicitely asked for
the connection to be closed.

What is strange about both of these is that I cannot
reproduce it in simple test cases, and the problems
happen intermittently.  I have some (large) programs that
exhibit this behavior reliably, but it seems to depend
on a number of factors:  The program iterates over many
connections and fails constantly in one iteration with
one version of cygwin.dll, and constantly in a later
iteration with a different version of the .dll.  It
also seems to fail much later when debugging (STRACE=1,out)
is turned on.  This seems to indicate some sort of
race condition, or possibly a corruption bug that is
trashing some internal state.

I see this behaviour in all the cygwin.dll's I have tried
it on, and am guessing that this problem has existed in
all versions of the dll (possibly a winsock bug).

Has anyone observed this behavior and looked into it?
Is it possible for my program to be trashing the cygwin
internal state, or would corruption of winsock state
have to be in the winsock dll itself?

                                         Tim N.

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

             reply	other threads:[~1997-10-06 14:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-10-06 14:47 Tim Newsham [this message]
1997-10-07  0:07 Sergey Okhapkin
1997-10-07 12:32 ` Tim Newsham
1997-10-07 12:32 Khosla, Deepak
1997-10-09 15:19 Colin Peters
1997-10-10 15:04 corruption in socket layer?] Jim Thompson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=199710062146.LAA18698@haleakala.aloha.net \
    --to=newsham@aloha.net \
    --cc=gnu-win32@cygnus.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).