gpsd-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gpsd-users] gpsd performing orderly socket shutdown


From: Tomalak Geret'kal
Subject: Re: [gpsd-users] gpsd performing orderly socket shutdown
Date: Fri, 30 Mar 2012 14:05:56 +0100
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:10.0.1) Gecko/20120208 Thunderbird/10.0.1

On 30/03/2012 13:55, Eric S. Raymond wrote:
Tomalak Geret'kal<address@hidden>:
So my question is, **under what circumstances might gpsd perform a
shutdown of a client connection**? Any at all?
Timeout after a failed write to the client.

One of the known problems with sockets is that you can never know for
sure whether quiescence from the remote end means (a) it has nothing to
say to you, or (b) it has died.

In order to avoid a resource leak due to clients flaking out, gpsd notices
when a write to the client fails and (in effect) starts a timer.  If the
timer expires before another write succeeds, the client is considered dead
and the connection dropped.
Thanks Eric.

Hopefully that'll help me narrow things down. I might just leave it as a "the socket blows up once in a while" and add some resilience for the scenario, though the relative frequency of its occurrence is worrying me a little.

Cheers

Tom



reply via email to

[Prev in Thread] Current Thread [Next in Thread]