Re: accept() fails with EINTER

2005-02-24 Thread linux-os
On Thu, 24 Feb 2005 [EMAIL PROTECTED] wrote: Trying to run an old server with a new kernel. A connection fails with "interrupted system call" as soon as a client attempts to connect. A trap in the code to continue works, but subsequent send() and recv() calls fail in the same way. Weren't you suppo

Re: accept() fails with EINTER

2005-02-24 Thread Folkert van Heusden
> Trying to run an old server with a new kernel. A connection > fails with "interrupted system call" as soon as a client > attempts to connect. A trap in the code to continue > works, but subsequent send() and recv() calls fail in > the same way. Weren't you supposed to just 'try again' when recei

Re: accept() fails with EINTER

2005-02-23 Thread Robert Hancock
linux-os wrote: Trying to run an old server with a new kernel. A connection fails with "interrupted system call" as soon as a client attempts to connect. A trap in the code to continue works, but subsequent send() and recv() calls fail in the same way. Anybody know how to mask that SIGIO (or whatev

RE: accept

2001-02-05 Thread Richard B. Johnson
On Sun, 4 Feb 2001, Mathieu Dube wrote: > Ok, but fd 0 cant be a valid socket since its the stdin > Sure it can: close(0); close(1); close(2); fd = socket(); dupetc, for stdout and stderr. That said, never, never, ever, check the value of the err

RE: accept

2001-02-04 Thread David Schwartz
> Ok, but fd 0 cant be a valid socket since its the stdin Wrong. fd 0 can be a valid socket. Read the man page to 'accept' again. Remember again that zero is a non-negative integer. > I posted that on this mailing list coz I thought that this might > be a scaling > problem since it happ

RE: accept

2001-02-04 Thread J . A . Magallon
On 02.04 Mathieu Dube wrote: > Ok, but fd 0 cant be a valid socket since its the stdin > > I posted that on this mailing list coz I thought that this might be a scaling > problem since it happens when theres already several clients connected to the > server > It just mean that your stdin was c

Re: accept

2001-02-04 Thread W1012
In article <01020411401700.00110@grndctrl> you wrote: > Ok, but fd 0 cant be a valid socket since its the stdin if you have closed stdin (like all daemons usually do) you will get fd 0 on next open. There is nothing magical about fd0 or fd1. Greetings Bernd - To unsubscribe from this list: send t

Re: accept

2001-02-04 Thread Mathieu Dube
On Sat, 03 Feb 2001, you wrote: > > What does it typically mean when accept returns 0 > > and that the perror outputs "Interupted system call"?? > > During the call, your process received a signal. > Most system calls are affected in this way, so that > you may break out of what you are doing by

RE: accept

2001-02-04 Thread Mathieu Dube
Ok, but fd 0 cant be a valid socket since its the stdin I posted that on this mailing list coz I thought that this might be a scaling problem since it happens when theres already several clients connected to the server On Sun, 04 Feb 2001, David Schwartz wrote: > > What does it typically mean wh

RE: accept

2001-02-04 Thread David Schwartz
> What does it typically mean when accept returns 0 > and that the perror outputs "Interupted system call"?? Since 'accept' returning zero is not an error, the results of 'perror' are meaningless. Please read the manual page for 'accept' and notice that it says, "The call returns -1 on e