[Qt-interest] QTcpServer timeout ?

Stephen Collyer scollyer at netspinner.co.uk
Wed Jul 21 14:38:16 CEST 2010


On 20 July 2010 20:50, David Boosalis <david.boosalis at gmail.com> wrote:

> II never see a disconnect, but the socket just seems to go to sleep as data
> fails to arrive to the server.  I was wondering if a time out occurring due
> to  the lack of activity going across the socket.


TCP connections don't time out for lack of activity. I see below that you've
tried
to fix the problem by enabling the Keepalive timeout on the socket, but I'd
be surprised if that fixes the problem, as it essentially does the opposite
of
what you want: it forces the kernel to close the socket underneath your app.
if the TCP stack gets no response from the other end of the connection.

If your connection is "going to sleep", what actually happens in your
program,
when you try to send, or expect to receive, data ?

-- 
Stephen Collyer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20100721/3b469357/attachment.html 


More information about the Qt-interest-old mailing list