Re: select() fails on multi-byte input in cygwin console (since 1.7.10)

2014-12-10 Thread Corinna Vinschen
On Dec 10 08:03, Thomas Wolff wrote: > Hi Corinna, > > Am 09.12.2014 um 12:19 schrieb Corinna Vinschen: > >Hi Thomas, > > > >On Dec 9 08:02, Thomas Wolff wrote: > >>Calling select() to check whether input from the terminal is available > >>fails for all but the first byte in the cygwin console if

Re: select() fails on multi-byte input in cygwin console (since 1.7.10)

2014-12-09 Thread Thomas Wolff
Hi Corinna, Am 09.12.2014 um 12:19 schrieb Corinna Vinschen: Hi Thomas, On Dec 9 08:02, Thomas Wolff wrote: Calling select() to check whether input from the terminal is available fails for all but the first byte in the cygwin console if multiple bytes are entered at once, like function or cur

Re: select() fails on multi-byte input in cygwin console (since 1.7.10)

2014-12-09 Thread Corinna Vinschen
Hi Thomas, On Dec 9 08:02, Thomas Wolff wrote: > Calling select() to check whether input from the terminal is available > fails for all but the first byte in the cygwin console if multiple bytes > are entered at once, like function or cursor keys or non-ASCII UTF-8 > characters. > Actually, the i

Re: select() not interrupted by signals

2013-01-13 Thread Thomas Wolff
Am 12.01.2013 20:14, schrieb Christopher Faylor: On Sat, Jan 12, 2013 at 06:41:27PM +0100, Thomas Wolff wrote: Am 11.01.2013 16:38, schrieb Christopher Faylor: On Fri, Jan 11, 2013 at 09:41:37AM +0100, Thomas Wolff wrote: ... ... select() is not restartable like read() or write(). That behav

Re: select() not interrupted by signals

2013-01-12 Thread Christopher Faylor
On Sat, Jan 12, 2013 at 06:41:27PM +0100, Thomas Wolff wrote: >Am 11.01.2013 16:38, schrieb Christopher Faylor: >> On Fri, Jan 11, 2013 at 09:41:37AM +0100, Thomas Wolff wrote: >>> I had previously reported "select() hanging after terminal killed" >>> (http://cygwin.com/ml/cygwin/2011-05/msg00418.h

Re: select() not interrupted by signals

2013-01-12 Thread Thomas Wolff
Am 11.01.2013 16:38, schrieb Christopher Faylor: On Fri, Jan 11, 2013 at 09:41:37AM +0100, Thomas Wolff wrote: I had previously reported "select() hanging after terminal killed" (http://cygwin.com/ml/cygwin/2011-05/msg00418.html). It turns out that select() does not get interrupted by a SIGWINCH

Re: select() not interrupted by signals

2013-01-11 Thread Christopher Faylor
On Fri, Jan 11, 2013 at 09:41:37AM +0100, Thomas Wolff wrote: >I had previously reported "select() hanging after terminal killed" >(http://cygwin.com/ml/cygwin/2011-05/msg00418.html). >It turns out that select() does not get interrupted by a SIGWINCH signal >either (with likely the same cause). >

Re: select() not interrupted by signals

2013-01-11 Thread Corinna Vinschen
On Jan 11 13:55, Thomas Wolff wrote: > On 11.01.2013 09:52, Corinna Vinschen wrote: > >On Jan 11 09:41, Thomas Wolff wrote: > >>I had previously reported "select() hanging after terminal killed" > >>(http://cygwin.com/ml/cygwin/2011-05/msg00418.html). > >>It turns out that select() does not get int

Re: select() not interrupted by signals

2013-01-11 Thread Thomas Wolff
On 11.01.2013 09:52, Corinna Vinschen wrote: On Jan 11 09:41, Thomas Wolff wrote: I had previously reported "select() hanging after terminal killed" (http://cygwin.com/ml/cygwin/2011-05/msg00418.html). It turns out that select() does not get interrupted by a SIGWINCH signal either (with likely t

Re: select() not interrupted by signals

2013-01-11 Thread Corinna Vinschen
On Jan 11 09:41, Thomas Wolff wrote: > I had previously reported "select() hanging after terminal killed" > (http://cygwin.com/ml/cygwin/2011-05/msg00418.html). > It turns out that select() does not get interrupted by a SIGWINCH > signal either (with likely the same cause). > This raises problems w

Re: select() hanging after terminal killed

2011-05-26 Thread Thomas Wolff
On 29.04.2010 17:21, Christopher Faylor wrote: On Thu, Apr 29, 2010 at 05:11:00PM +0200, Corinna Vinschen wrote: On Apr 29 12:53, Thomas Wolff wrote: If a terminal gets killed, its tty/pty is not properly closed. This is likely to confuse applications and let them hang, as observed with mined (

Re: select() hanging after terminal killed

2010-04-29 Thread Matthias Andree
Thomas Wolff wrote on 2010-04-29: On 29.04.2010 13:28, Matthias Andree wrote: Am 29.04.2010 12:53, schrieb Thomas Wolff: [on closed terminal] On Linux, select() indicates an exception and EIO. On SunOS, select() indicates both an exception and input (weird), Not weird, you appear to be mis

Re: select() hanging after terminal killed

2010-04-29 Thread Christopher Faylor
On Thu, Apr 29, 2010 at 05:11:00PM +0200, Corinna Vinschen wrote: >On Apr 29 12:53, Thomas Wolff wrote: >> If a terminal gets killed, its tty/pty is not properly closed. >> This is likely to confuse applications and let them hang, as observed >> with mined (thanks Andy for the report) and joe. >>

Re: select() hanging after terminal killed

2010-04-29 Thread Corinna Vinschen
On Apr 29 12:53, Thomas Wolff wrote: > If a terminal gets killed, its tty/pty is not properly closed. > This is likely to confuse applications and let them hang, as observed > with mined (thanks Andy for the report) and joe. > > On Linux and SunOS, a subsequent read() return 0 (indicating EOF); >

Re: select() hanging after terminal killed

2010-04-29 Thread Thomas Wolff
On 29.04.2010 13:28, Matthias Andree wrote: Am 29.04.2010 12:53, schrieb Thomas Wolff: [on closed terminal] On Linux, select() indicates an exception and EIO. On SunOS, select() indicates both an exception and input (weird), Not weird, you appear to be misunderstanding select(). An I

Re: select() hanging after terminal killed

2010-04-29 Thread Matthias Andree
Am 29.04.2010 12:53, schrieb Thomas Wolff: [on closed terminal] > On Linux, select() indicates an exception and EIO. > On SunOS, select() indicates both an exception and input (weird), Not weird, you appear to be misunderstanding select(). An IEEE Std 1003.1 compliant select(): - only states th

Re: select() and named pipes

2010-02-16 Thread Enrico Forestieri
On Mon, Feb 15, 2010 at 10:16:55PM -0500, Christopher Faylor wrote: > On Tue, Feb 16, 2010 at 02:20:55AM +0100, Enrico Forestieri wrote: > >On Sun, Feb 14, 2010 at 08:54:27PM -0500, Christopher Faylor wrote: > > > >> I just checked in YA in my series of attempts to get this working right. > >> It

Re: select() and named pipes

2010-02-15 Thread Christopher Faylor
On Tue, Feb 16, 2010 at 02:20:55AM +0100, Enrico Forestieri wrote: >On Sun, Feb 14, 2010 at 08:54:27PM -0500, Christopher Faylor wrote: > >> I just checked in YA in my series of attempts to get this working right. >> It will behave marginally better now but there are still problems if you >> attemp

Re: select() and named pipes

2010-02-15 Thread Enrico Forestieri
On Sun, Feb 14, 2010 at 08:54:27PM -0500, Christopher Faylor wrote: > I just checked in YA in my series of attempts to get this working right. > It will behave marginally better now but there are still problems if you > attempt to write to a fifo before anything is reading it and then try to > do

Re: select() and named pipes

2010-02-14 Thread Christopher Faylor
On Sun, Jan 03, 2010 at 02:11:21PM -0500, Christopher Faylor wrote: >On Sun, Jan 03, 2010 at 05:58:46PM +0100, Enrico Forestieri wrote: >>On Wed, Dec 23, 2009 at 03:12:19AM +0100, Enrico Forestieri wrote: >>> On Tue, Dec 22, 2009 at 07:37:14PM -0500, Christopher Faylor wrote: >>> > On Tue, Dec 22,

Re: select() and named pipes

2010-01-03 Thread Christopher Faylor
On Sun, Jan 03, 2010 at 05:58:46PM +0100, Enrico Forestieri wrote: >On Wed, Dec 23, 2009 at 03:12:19AM +0100, Enrico Forestieri wrote: >> On Tue, Dec 22, 2009 at 07:37:14PM -0500, Christopher Faylor wrote: >> > On Tue, Dec 22, 2009 at 11:43:09PM +0100, Enrico Forestieri wrote: >> > >I am experienci

Re: select() and named pipes

2010-01-03 Thread Enrico Forestieri
On Wed, Dec 23, 2009 at 03:12:19AM +0100, Enrico Forestieri wrote: > On Tue, Dec 22, 2009 at 07:37:14PM -0500, Christopher Faylor wrote: > > On Tue, Dec 22, 2009 at 11:43:09PM +0100, Enrico Forestieri wrote: > > >I am experiencing a problem with select() and named pipes in cygwin > > >1.7. The att

Re: select() and named pipes

2009-12-22 Thread Enrico Forestieri
On Tue, Dec 22, 2009 at 07:37:14PM -0500, Christopher Faylor wrote: > On Tue, Dec 22, 2009 at 11:43:09PM +0100, Enrico Forestieri wrote: > >I am experiencing a problem with select() and named pipes in cygwin > >1.7. The attached test case segfaults on the select() call, but works > >fine with both

Re: select() and named pipes

2009-12-22 Thread Christopher Faylor
On Tue, Dec 22, 2009 at 11:43:09PM +0100, Enrico Forestieri wrote: >I am experiencing a problem with select() and named pipes in cygwin >1.7. The attached test case segfaults on the select() call, but works >fine with both cygwin 1.5 and linux. Thanks for the test case. This should be fixed in t

Re: select() and named pipes

2009-12-22 Thread Dave Korn
Enrico Forestieri wrote: > I am experiencing a problem with select() and named pipes in cygwin 1.7. > The attached test case segfaults on the select() call, but works fine > with both cygwin 1.5 and linux. Confirmed. It appears that start_thread_pipe() is called for both pipes and fifos, but on

Re: Select Packages blows up to full-screen (setup-1.7.exe)

2009-09-17 Thread Christopher Faylor
On Thu, Sep 17, 2009 at 06:50:39PM -0600, Jim Reisert AD1C wrote: >On Thu, Sep 17, 2009 at 5:18 PM, Larry Hall (Cygwin) > wrote: >>On 09/17/2009 06:42 PM, Jim Reisert AD1C wrote: >>> >>>Is there some reason why setup-1.7 has to blow up to full-screen when >>>the "Select Packages" screen comes up?

Re: Select Packages blows up to full-screen (setup-1.7.exe)

2009-09-17 Thread Jim Reisert AD1C
On Thu, Sep 17, 2009 at 5:18 PM, Larry Hall (Cygwin) wrote: > On 09/17/2009 06:42 PM, Jim Reisert AD1C wrote: >> >> Is there some reason why setup-1.7 has to blow up to full-screen when >> the "Select Packages" screen comes up?  I prefer the friendlier 1.5 >> version. > > Yes, it was changed so t

Re: Select Packages blows up to full-screen (setup-1.7.exe)

2009-09-17 Thread Larry Hall (Cygwin)
On 09/17/2009 06:42 PM, Jim Reisert AD1C wrote: Is there some reason why setup-1.7 has to blow up to full-screen when the "Select Packages" screen comes up? I prefer the friendlier 1.5 version. Yes, it was changed so that you could easily see all the information in the packages listed. As a b

Re: Select Packages blows up to full-screen (setup-1.7.exe)

2009-09-17 Thread Jim Reisert AD1C
On Thu, Sep 17, 2009 at 4:42 PM, Jim Reisert AD1C wrote: > Is there some reason why setup-1.7 has to blow up to full-screen when > the "Select Packages" screen comes up?  I prefer the friendlier 1.5 > version. I forgot to mention, that the back/cancel etc. icons at the bottom end up buried under

Re: Select-all Vista install fails?

2007-11-27 Thread joekrahn
Peter Klavins wrote: > > I am a very satisfied user of Cygwin for many years, and on Vista since > Nov 2006. I always download and keep updated all packages, since I > usually find that something is missing when I really need it. Recently > I was presented with the opportunity to install Cygw

RE: Select-all Vista install fails?

2007-11-26 Thread Peter Klavins
> > So my question is this: Is Cygwin supposed to install fully on Vista from > > an initial All-package-selection? > > Yes. Rats. I was hoping for an answer like "Installation on Vista is a two- step process, first complete an installation with the default package selections and make your init

Re: Select-all Vista install fails?

2007-11-25 Thread Larry Hall (Cygwin)
On 11/23/2007, Peter Klavins wrote: So my question is this: Is Cygwin supposed to install fully on Vista from an initial All-package-selection? Yes. If so, what did I do wrong in the install? That's unclear. Sort of sacrificing your first-born to Vista, it would seem the only logical way

Re: select failed: Interrupted system call

2006-12-29 Thread Václav Haisman
andy wang wrote, On 25.12.2006 23:12: > Hi, All: > > What's the reason can cause interrupted system call. the same program > will not be interrupted running at linux. I know a singal can, Is > there anything else can? Is there possible that pthread_cond_signal > will do the same thing too? > >

Re: select() too slow

2006-03-19 Thread Pedro Inacio
Yes! I've confirmed that! With TCP_NODELAY Cygwin and Linux times are similar. It seems that there is some issue with the Naggle algorithm on Windows for sure. Thanks Pedro Inacio On 2006/03/15, at 21:49, Corinna Vinschen wrote: It looks like this is a TCP_NODELAY issue. You tend to g

Re: select() too slow

2006-03-15 Thread Corinna Vinschen
On Mar 15 19:07, Pedro Inacio wrote: > > On 2006/03/14, at 22:43, Christopher Faylor wrote: > > >On Tue, Mar 14, 2006 at 09:42:25PM +, Pedro Inacio wrote: > > > >I don't have any 100MB files sitting around but when I tried this on a > >14MB file, I find that cygwin is about 2X slower, not an

Re: select() too slow

2006-03-15 Thread Christopher Faylor
On Wed, Mar 15, 2006 at 07:07:05PM +, Pedro Inacio wrote: >On 2006/03/14, at 22:43, Christopher Faylor wrote: > >>On Tue, Mar 14, 2006 at 09:42:25PM +, Pedro Inacio wrote: >> >>I don't have any 100MB files sitting around but when I tried this on a >>14MB file, I find that cygwin is about 2X

Re: select() too slow

2006-03-15 Thread Pedro Inacio
On 2006/03/14, at 22:43, Christopher Faylor wrote: On Tue, Mar 14, 2006 at 09:42:25PM +, Pedro Inacio wrote: I don't have any 100MB files sitting around but when I tried this on a 14MB file, I find that cygwin is about 2X slower, not an order of magnitude slower. Taking away the pipe and

Re: select() too slow

2006-03-14 Thread Christopher Faylor
On Tue, Mar 14, 2006 at 09:42:25PM +, Pedro Inacio wrote: >I'm goin to explain everything step by step in order to be now doubts. > >One computer with dual boot, Linux in one partition and Windows with >Cygwin installed on another partition. > >Boot on Linux compile echo_server.c, run it and

Re: select() too slow

2006-03-14 Thread Pedro Inacio
I'm goin to explain everything step by step in order to be now doubts. One computer with dual boot, Linux in one partition and Windows with Cygwin installed on another partition. Boot on Linux compile echo_server.c, run it and it will listen on tcp port 12345 Imagine that the IP address of

Re: select() too slow

2006-03-14 Thread Christopher Faylor
On Tue, Mar 14, 2006 at 07:32:09PM -, Dave Korn wrote: >On 14 March 2006 19:19, Christopher Faylor wrote: >>On Tue, Mar 14, 2006 at 06:59:28PM +, Pedro Inacio wrote: >>>Hello again, >>> >>>as promised attached you will find a very simplistic non-blocking echo >>>server that compiles on Linu

RE: select() too slow

2006-03-14 Thread Dave Korn
On 14 March 2006 19:19, Christopher Faylor wrote: > On Tue, Mar 14, 2006 at 06:59:28PM +, Pedro Inacio wrote: >> Hello again, >> >> as promised attached you will find a very simplistic non-blocking >> echo server that compiles on Linux and Cygwin. >> The main objective is that you compile it

Re: select() too slow

2006-03-14 Thread Christopher Faylor
On Tue, Mar 14, 2006 at 06:59:28PM +, Pedro Inacio wrote: >Hello again, > >as promised attached you will find a very simplistic non-blocking >echo server that compiles on Linux and Cygwin. >The main objective is that you compile it and run on both environments. >Of course that the same hardwa

Re: select() too slow

2006-03-14 Thread Pedro Inacio
Hello again, as promised attached you will find a very simplistic non-blocking echo server that compiles on Linux and Cygwin. The main objective is that you compile it and run on both environments. Of course that the same hardware is recommended in order to compare the results in a more accu

Re: select() too slow

2006-03-11 Thread Pedro Inacio
On 2006/03/11, at 18:16, Christopher Faylor wrote: But we don't know what the actual problem *is*. What does "too slow" mean? select takes an extra twenty milliseconds under Cygwin? select doesn't respond within 24 hours? You are right, I recognize that I haven't gave sufficient detai

Re: select() too slow

2006-03-11 Thread Christopher Faylor
On Sat, Mar 11, 2006 at 06:04:37PM +, Pedro Inacio wrote: >On 2006/03/11, at 15:40, Eric Blake wrote: > >> >>I'm afraid that this is not a very good bug report, as you have not >>attempted to describe WHAT is too slow, and have not provided a simple >>test case that compiles out of the box, wit

Re: select() too slow

2006-03-11 Thread Pedro Inacio
On 2006/03/11, at 15:40, Eric Blake wrote: I'm afraid that this is not a very good bug report, as you have not attempted to describe WHAT is too slow, and have not provided a simple test case that compiles out of the box, with timing numbers on the test case compared between Linux and Cygwi

Re: select() too slow

2006-03-11 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 According to Pedro Inacio on 3/11/2006 3:11 AM: > > Since I want to run the application on Windows also, I have ported it to > run on Cygwin. > Everything is ok except the poor performance of the select() function. > It is too dam slow. I'm afraid th

Re: Select()

2006-02-03 Thread Jim Easton
> From [EMAIL PROTECTED] Fri Feb 3 01:10:29 2006 > Date: Fri, 03 Feb 2006 00:10:02 -0800 > From: Brian Dessent <[EMAIL PROTECTED]> > To: cygwin@cygwin.com > Subject: Re: Select() > Reply-To: cygwin@cygwin.com Brian Dessent wrote: > Jim Easton wrote: > > >

Re: Select()

2006-02-03 Thread Brian Dessent
Jim Easton wrote: > I hate to display my ignorance like this but where does one find > "how-signals-work.txt"? Google didn't help me much. http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/cygwin/?cvsroot=src -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports:

Re: Select()

2006-02-02 Thread Jim Easton
Hi, Brian Dessent wrote: > Vinod Chowdappa wrote: > > > Could you briefly explain the format of the .din file? What does SIGFE mean? > > Does "select = cygwin_select SIGFE" mean select is a weak alias to > > cygwin_select? > > And cygwin_select is itself not exported? > > You need to read the fi

Re: Select()

2006-02-02 Thread Brian Dessent
Vinod Chowdappa wrote: > Could you briefly explain the format of the .din file? What does SIGFE mean? > Does "select = cygwin_select SIGFE" mean select is a weak alias to > cygwin_select? > And cygwin_select is itself not exported? You need to read the file "how-signals-work.txt" which explains t

Re: Select()

2006-02-02 Thread Corinna Vinschen
On Feb 2 18:55, Vinod Chowdappa wrote: > On 2/2/06, Corinna Vinschen <[EMAIL PROTECTED]> wrote: > > > in cygwin.din. Not sure what this file is and how is it used exactly? > > > > See the Makefile. cygwin.din is converted to cygwin.def, a standard > > export definition file for the linker. > > C

Re: Select()

2006-02-02 Thread Vinod Chowdappa
Hi On 2/2/06, Corinna Vinschen <[EMAIL PROTECTED]> wrote: > > I see these lines, > > > > _select = cygwin_select SIGFE > > select = cygwin_select SIGFE > > > > in cygwin.din. Not sure what this file is and how is it used exactly? > > See the Makefile. cygwin.din is converted to cygwin.def, a stan

Re: Select()

2006-02-02 Thread Corinna Vinschen
On Feb 2 16:50, Vinod Chowdappa wrote: > Hi, > > Could somebody tell me how is select() resolved to cygwin_select() eventually? > > I believe cygwin_select() is the core select() implementation, but to > the user it is the POSIX API select() that is exported. > > I see these lines, > > _select

Re: select() hangs forever with Cygwin 1.5.18 on WinXP

2005-10-04 Thread Corinna Vinschen
On Oct 4 09:43, Vladislav Grinchenko wrote: > Hi, > > I am trying to use UNIX domain sockets in cygwin environment. > A program in question works fine just on any other POSIX > OS I can get my hands on (Linux, FreeBSD, Solaris, ...). > However, running on cygwin, select() hangs forever. > > T

Re: Select() hangs forever

2005-04-29 Thread Corinna Vinschen
On Apr 28 11:48, Vladislav Grinchenko wrote: > A small test program creates a UNIX domain socket and listens on an > incoming connections. Then, from the same process, two ASYNC connections > are attempted (think of it as a loopback within a process). Calling > connect() on both returns "errno: 119

Re: select/listen (win xp sp1) bug, due to Windows login somehow.

2005-02-28 Thread Bryan O'Donoghue
I tried it nevertheless. I logged out and in a couple of times. No problem here, neither on 1.5.12 nor on current CVS. Corinna Thank god. In that case it is almost certainly a pecularity of my box, and isn't a show stopper for the application I noticed this bug on. I'll see if I can replicate t

RE: select/listen (win xp sp1) bug, due to Windows login somehow.

2005-02-28 Thread Dave Korn
Original Message >From: Corinna Vinschen >Sent: 28 February 2005 18:16 > On Feb 28 18:00, Dave Korn wrote: >>> From: cygwin-owner On Behalf Of Bryan O'Donoghue >>> However, if you do start the login process and poll programatically/by >>> hand the service to return data, you should notice

Re: select/listen (win xp sp1) bug, due to Windows login somehow.

2005-02-28 Thread Corinna Vinschen
On Feb 28 18:00, Dave Korn wrote: > >From: cygwin-owner On Behalf Of Bryan O'Donoghue > > However, if you do start the login process and poll programatically/by > > hand the service to return data, you should notice as I have that > > roughly 1-2 seconds before the full login, to the Windows deskt

RE: select/listen (win xp sp1) bug, due to Windows login somehow.

2005-02-28 Thread Dave Korn
Original Message >From: cygwin-owner On Behalf Of Bryan O'Donoghue >Sent: 28 February 2005 15:01 > b) You reboot the machine and _don't_ log in. If you simply leave the > machine at the login prompt, this particular Windows Service, will > always behave as expected. > However, if you do

Re: select() read() and write() on /dev/console

2004-11-23 Thread Jason Curl
Christopher Faylor cygwin.com> writes: > > On Mon, Nov 22, 2004 at 05:18:46PM +, Jason Curl wrote: > >Where is fds[0] defined, so I can see exactly what functions are being > >called by peek_console, etc.? e.g. fh->get_readahead_valid(); > >fh->bg_check(SIGTTIN). > > Also in dtable.cc. L

Re: select() read() and write() on /dev/console

2004-11-22 Thread Christopher Faylor
On Mon, Nov 22, 2004 at 05:18:46PM +, Jason Curl wrote: >Where is fds[0] defined, so I can see exactly what functions are being >called by peek_console, etc.? e.g. fh->get_readahead_valid(); >fh->bg_check(SIGTTIN). Also in dtable.cc. Look for the obvious. -- Unsubscribe info: http://c

Re: select() read() and write() on /dev/console

2004-11-22 Thread Jason Curl
Christopher Faylor cygwin.com> writes: > In dtable::select_{read,write,except} . > > cgf Where is fds[0] defined, so I can see exactly what functions are being called by peek_console, etc.? e.g. fh->get_readahead_valid(); fh->bg_check(SIGTTIN). Thanks. -- Unsubscribe info: http://cygw

Re: select() read() and write() on /dev/console

2004-11-22 Thread Christopher Faylor
On Mon, Nov 22, 2004 at 02:53:20PM +, Jason Curl wrote: >Christopher Faylor cygwin.com> writes: >>On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: >>>My question, how do I go about investigating what the root cause is? >>>Has anybody else seen similar issues and been able to work ar

Re: select() read() and write() on /dev/console

2004-11-22 Thread Jason Curl
Christopher Faylor cygwin.com> writes: > > On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: > >My question, how do I go about investigating what the root cause is? Has > >anybody else seen similar issues and been able to work around it? I'm > >stuck and I've never seen the source co

Re: select() read() and write() on /dev/console

2004-11-21 Thread Jason Curl
Christopher Faylor cygwin.com> writes: > > On Sun, Nov 21, 2004 at 07:00:42PM +0100, Jason Curl wrote: > >Christopher Faylor wrote: > >>On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: > >> > >>>My question, how do I go about investigating what the root cause is? Has > >>>anybody els

Re: select() read() and write() on /dev/console

2004-11-21 Thread Christopher Faylor
On Sun, Nov 21, 2004 at 07:00:42PM +0100, Jason Curl wrote: >Christopher Faylor wrote: >>On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: >> >>>My question, how do I go about investigating what the root cause is? Has >>>anybody else seen similar issues and been able to work around it? I

Re: select() read() and write() on /dev/console

2004-11-21 Thread Jason Curl
Christopher Faylor wrote: On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: My question, how do I go about investigating what the root cause is? Has anybody else seen similar issues and been able to work around it? I'm stuck and I've never seen the source code to cygwin before. If you

Re: select() read() and write() on /dev/console

2004-11-21 Thread Jason Curl
Christopher Faylor wrote: On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: My question, how do I go about investigating what the root cause is? Has anybody else seen similar issues and been able to work around it? I'm stuck and I've never seen the source code to cygwin before. If you

Re: select() read() and write() on /dev/console

2004-11-19 Thread Christopher Faylor
On Fri, Nov 19, 2004 at 06:46:56PM +0100, Jason Curl wrote: >My question, how do I go about investigating what the root cause is? Has >anybody else seen similar issues and been able to work around it? I'm >stuck and I've never seen the source code to cygwin before. If you suspect a problem with

Re: select call does block unless data arrives at socket (when waiting for serial port and ip socket)

2004-09-29 Thread Brian Ford
On Wed, 29 Sep 2004, Stefan Mahr wrote: > I want to use select() to wait for a serial port and a ip socket. > Following problem: > If data arrives the serial port, select() works as aspected and returns 1. > If data arrives the ip socket, select() doesn't return. > If data arrives the serial port

Re: select call does block unless data arrives at socket (when waiting for serial port and ip socket)

2004-09-29 Thread Christopher Faylor
On Wed, Sep 29, 2004 at 11:09:03PM +0200, Stefan Mahr wrote: >Hi... > >I want to use select() to wait for a serial port and a ip socket. >Following problem: >If data arrives the serial port, select() works as aspected and returns 1. >If data arrives the ip socket, select() doesn't return. >If data

RE: "select" returns error "Bad file descriptor" when called with a copy of "svc_fdset" (defined at "rpc.h") as it's readfds argument

2004-06-28 Thread Dave Korn
> -Original Message- > From: cygwin-owner On Behalf Of Dave Korn > Sent: 28 June 2004 14:13 > > -Original Message- > > From: cygwin-owner On Behalf Of Dave Korn > > Sent: 28 June 2004 13:24 > > > > -Original Message- > > > From: cygwin-owner On Behalf Of Lev Pliner > > > S

RE: "select" returns error "Bad file descriptor" when called with a copy of "svc_fdset" (defined at "rpc.h") as it's readfds argument

2004-06-28 Thread Dave Korn
> -Original Message- > From: cygwin-owner On Behalf Of Dave Korn > Sent: 28 June 2004 13:24 > > -Original Message- > > From: cygwin-owner On Behalf Of Lev Pliner > > Sent: 28 June 2004 12:38 > > > I once again ask you to help me to solve my problem. I > > attached an easy > > exa

RE: "select" returns error "Bad file descriptor" when called with a copy of "svc_fdset" (defined at "rpc.h") as it's readfds argument

2004-06-28 Thread Dave Korn
> -Original Message- > From: cygwin-owner On Behalf Of Lev Pliner > Sent: 28 June 2004 12:38 > I once again ask you to help me to solve my problem. I > attached an easy > example that works under Linux and FreeBSD. Your code doesn't even compile. There's no such include file as rpc/r

Re: select() hangs sometimes, for TCP connections

2004-03-10 Thread Patrick Samson
Sorry, I was wrong. Tcl-DP was not the primary cause. The story goes on at: "Backend doesn't catch the next command, after SIGUSR2" http://cygwin.com/ml/cygwin/2004-03/msg00418.html This time with a simpler context: only pgtclsh and Postgresql. --- Patrick Samson wrote: > I finally found the culp

Re: select() hangs sometimes, for TCP connections

2004-02-26 Thread Patrick Samson
I finally found the culprit. It seems to be a Tcl extension which was badly built. The DB replication scripts are written in Tcl. For the communication between hosts, the extension Tcl-DP is used, with TCP socket channels. The extension is provided as C sources. So I had to build a DLL. The windo

Re: select() hangs sometimes, for TCP connections

2004-02-18 Thread Patrick Samson
I run the process blocking in select() with strace. It now runs correctly, but the TCL scenario blocks elsewhere on a "eval exec bash ...". gdb seems to show a freeze in a call to a ReadFile() function -> again something with file descriptors. So, I put this command in a strace as well. Guess what

Re: select() hangs sometimes, for TCP connections

2004-02-13 Thread Christopher Faylor
On Fri, Feb 13, 2004 at 08:28:36PM +0100, Corinna Vinschen wrote: >On Feb 13 09:32, Christopher Faylor wrote: >>On Fri, Feb 13, 2004 at 04:27:19AM -0800, Patrick Samson wrote: >>>Problem: sometimes select() doesn't return. >>> >>>Context: I run a DB replication scenario, with cron, everything 5 mn.

Re: select() hangs sometimes, for TCP connections

2004-02-13 Thread Corinna Vinschen
On Feb 13 09:32, Christopher Faylor wrote: > On Fri, Feb 13, 2004 at 04:27:19AM -0800, Patrick Samson wrote: > >Problem: sometimes select() doesn't return. > > > >Context: I run a DB replication scenario, with cron, everything 5 mn. > >There is no change in the DB, so the scenario is always the sam

Re: select() hangs sometimes, for TCP connections

2004-02-13 Thread Christopher Faylor
On Fri, Feb 13, 2004 at 04:27:19AM -0800, Patrick Samson wrote: >Problem: sometimes select() doesn't return. > >Context: I run a DB replication scenario, with cron, everything 5 mn. >There is no change in the DB, so the scenario is always the same. Most >of the time, it works. But eventually, aft

Re: Re: select() take 100% CPU with cygwin1.5.5-1 in WinXP/Win2000

2003-11-03 Thread zhouxin
I set a timeout for recvfrom() by calling select() on a UDP socket: socket()=>sendto()=>select()=>recvfrom(). It seems that it need not call bind() or connect() for UDP socket here. This method is recommended by "UNIX Network Programming Volum1 Networking APIs: Sockets and XTI(Second Edition)", W.

Re: select() take 100% CPU with cygwin1.5.5-1 in WinXP/Win2000

2003-10-31 Thread Corinna Vinschen
On Fri, Oct 31, 2003 at 01:14:17PM +0800, zhouxin wrote: > Cygwin implementation of select() take 100% CPU under multi-thread environment > sometimes. > [...] > if((sockfd = socket(AF_INET, SOCK_DGRAM, 0)) < 0){ > fprintf(stderr, "cannot open socket for udp packet!\n"); > exit(

Re: select() doesn't respond

2003-10-23 Thread Corinna Vinschen
On Thu, Oct 23, 2003 at 11:58:57AM +0900, Takeshi Honda wrote: > I got linux packet monitoring program, > and succeeded to build. > > But when I tried to run, select() doens't respond and > program stops. > > I use cygwin 1.5.5-1. > > What can I do for this? > Please let me know. RAW sockets ar

Re: select() doesn't respond

2003-10-22 Thread Brian Dessent
Takeshi Honda wrote: >if ((sock=socket(AF_INET,SOCK_RAW,IPPROTO_TCP))==-1){ > printf("Can not create RAW socket.\n"); > return -1; > } > > FD_ZERO(&read_fd); > FD_SET(sock,&read_fd); > select(FD_SETSIZE,&read_fd,NULL,NULL,NULL); // program > stop here You create a socket but