delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/08/02/10:55:31

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Date: Thu, 2 Aug 2001 10:52:43 -0400
From: Christopher Faylor <cgf AT redhat DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: problem/bug in select command of socket / winsock
Message-ID: <20010802105243.A28085@redhat.com>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <Pine DOT BSF DOT 4 DOT 33L2 DOT 0107251218280 DOT 37365-100000 AT msg DOT ucsf DOT edu>
Mime-Version: 1.0
User-Agent: Mutt/1.3.11i
In-Reply-To: <Pine.BSF.4.33L2.0107251218280.37365-100000@msg.ucsf.edu>; from haase@msg.ucsf.edu on Wed, Jul 25, 2001 at 12:31:08PM -0700

On Wed, Jul 25, 2001 at 12:31:08PM -0700, haase AT msg DOT ucsf DOT edu wrote:
>Hi,
>I wrote a C++ / wxWindows (very nice GUI lib :-) program.
>It normally handles TCP/IP socket communication by utilizing it's
>"event-handling" system - so that e.g.  recv() doesn't block the program
>until data arrives  -- all that works fine.
>
>But I have a extra / second thread dedicated just to read from a socket .
>This _HAS_ to block on recv - otherwise it would run in circles and use up
>100% CPU while waiting on data. This mode in wxWindows is activated with:
>socket->SetFlag(wxSOCKET_BLOCK).  I found that that is implemented by
>using a ("blocking") select()  [somewhere inside a part that wxWindows
>calls their GSocket implementation]
>
>So: all this works fine when I compile on VC++ (6)
>    But cygwin just seems to run right through the select() call  [ I used
>the gdb -- very fancy :-)) someone did a good job!! ]
>
>
>I read that there is an issue about if or how to use the winsock part or
>the posix-compliant cygwin version  .   Is that a way to influence that
>or did I just found a bug?

You really haven't provided enough details to tell if this is a bug
or not.

AFAIK, there aren't any issues with select on sockets.  If there were then
things like inetd or ssh would be inoperable.

cgf

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