06-09-06 12:24 PM
On 2006-06-08, Mark Harrison <mh@pixar.com> wrote:
> The external program is long running (a render job), so if
> the client dies or disconnects I would like to terminate
> the external program.
[...]
> But I get no events if the client terminates, until the
> external program terminates, in which case I get revents=5
> (POLLOUT|POLLIN).
Are you sure that you are checking the connection while your external
program runs? Could it be that you only write into socket and don't read
from it?
Normally if the peer application has closed connection, then your socket
becomes readable (POLLIN) and call to recv should return 0 to indicate
EOF.
--
Minds, like parachutes, function best when open
[ Post a follow-up to this message ]
|