delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/06/14/15:31:18

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <02bf01c213da$19283960$6132bc3e@BABEL>
From: "Conrad Scott" <Conrad DOT Scott AT dsl DOT pipex DOT com>
To: <cygwin AT cygwin DOT com>
References: <007f01c21348$72149600$5a6d3850 AT piggy> <08ce01c2134f$7e2a4a00$6132bc3e AT BABEL>
Subject: Re: Cygwin && TCP && O_NONBLOCK
Date: Fri, 14 Jun 2002 20:31:35 +0100
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2600.0000

"Conrad Scott" <Conrad DOT Scott AT dsl DOT pipex DOT com> wrote:
> So I assume you call connect(2) once then wait for select(2) or poll(2) to
> give you a writable status, which they do once the connection eventually
> succeeds or fails (this is mentioned in their respective man pages). So it
> looks like Linux is wrong and cygwin is right.

It occurred to me that I wasn't sure, on this account of non-blocking use of
connect(2), how to get hold of the connect/fail status of the connection,
once select(2) or poll(2) confirmed it was available. The answer: use
getsockopt(2) to check the SO_ERROR value. (Tho' I can't find mention of
this in any of the standards docs: just the Linux man pages.)

So that's okay then.

// Conrad




--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


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