[Top] [All Lists]

Re: PROBLEM: a local TCP socket close does not trigger a poll on the oth

To: "David S. Miller" <davem@xxxxxxxxxx>
Subject: Re: PROBLEM: a local TCP socket close does not trigger a poll on the other end
From: "Bernard MAUDRY" <support@xxxxxxxxxxxxx>
Date: Thu, 8 Mar 2001 18:34:28 +0100
Cc: netdev@xxxxxxxxxxx
In-reply-to: <15008.52456.168979.593594@xxxxxxxxxxxxxxx>
References: <3AA0DA38.23766.573498DB@localhost>
Sender: owner-netdev@xxxxxxxxxxx
> Set the FDs[0].events to some value other than zero, you are
> telling the kernel you are interested in "no events".  Read the
> poll() man page for details.

The man pages state :       The field events is an input parameter, a bitmask 
specifying the events the       application  is  interested  in.  The field 
is an output parameter,       filled by the kernel with the events that 
occurred, either of the type       requested, or of one of the types  POLLERR 
or  POLLHUP  or  POLLNVAL.       (These three bits are meaningless in the 
events field, and will be set in        the revents field whenever the 
corresponding condition is true.) 

So putting 0 in the events fields is a normal value when the application is 
insterested in the error cases. 

Anyway, I tried to put POLLPRI in the events field to avoid potential trouble 
any) with the 0 value. The behavior is the same: poll does not indicate the 
hangup of the other end. 

Best regards. 


|  Bernard MAUDRY                      |
|  Top Graph'X Customer Support        |
|  10, allee de la mare Jacob          |
|  91290 La Norville                   |
|  FRANCE                              |
|  Tel: (33) 1 69 26 97 88             |
|  Fax: (33) 1 69 26 97 89             |
|  email: support@xxxxxxxxxxxxx        |

<Prev in Thread] Current Thread [Next in Thread>