delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-developers/2002/08/28/07:28:55

Mailing-List: contact cygwin-developers-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-developers-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin-developers/>
List-Post: <mailto:cygwin-developers AT cygwin DOT com>
List-Help: <mailto:cygwin-developers-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-developers-owner AT cygwin DOT com
Delivered-To: mailing list cygwin-developers AT cygwin DOT com
Date: Wed, 28 Aug 2002 13:28:35 +0200
From: Corinna Vinschen <vinschen AT redhat DOT com>
To: cygapp <cygwin-apps AT cygwin DOT com>, cygdev <cygwin-developers AT cygwin DOT com>
Subject: HEADSUP: New behaviour of socket send/write functionality
Message-ID: <20020828132835.F5475@cygbert.vinschen.de>
Mail-Followup-To: cygapp <cygwin-apps AT cygwin DOT com>,
cygdev <cygwin-developers AT cygwin DOT com>
Mime-Version: 1.0
User-Agent: Mutt/1.3.22.1i

Hi,

I've just checked in a change to the socket function sendto() which
changes the behaviour when the socket has been shutdown, e.g. by the
peer.

In that case send() returned -1 and ESHUTDOWN so far.  According to
SUSv3 and Linux, send() *should* return EPIPE and raise the SIGPIPE
signal.  The Linux implementation additionally knows a flag called
MSG_NOSIGNAL which suppresses the SIGPIPE signal in that case.

My patch implements just that, returning EPIPE instead of ESHUTDOWN
and raising SIGPIPE if not MSG_NOSIGNAL is given in the flags argument.

I thought it would be good to give this heads up, since that fix could
change the behaviour of some applications.  I checked ssh, sshd, inetd
and friends, that they still work so the change doesn't break everything.

But I'd like to encourage the maintainers of socket related applications
to check, if their application still works as expected.  The change could
also coincidentally result in solving some problems about hanging apps
(rsync, perhaps?) but that's not sure, obviously.

Ok, that's all folks,
Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                                mailto:cygwin AT cygwin DOT com
Red Hat, Inc.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019