Jump to content
Sign in to follow this  
tsolrm

TCP is there a timeout?

Recommended Posts

tsolrm

I've got a tcp chat - a server and multiple clients

I've opened my client and was online but afk. after about 40 minutes i've tried to send a message but was dropped from the server.

I checked the server script - it was running. Is there some sort of limit for this?

The server is looped to recieve messages from each individual client and sends them back to all clients

The client is looped to recieve messages

Share this post


Link to post
Share on other sites
tsolrm

$NewMessage = TCPRecv ($TCPConnect, 100000)

If @error Then

$error = @error

GUIDelete ()

MsgBox (16, "test", "Lost connection: "&$error)

TCPCloseSocket($TCPConnect)

Exit

EndIf

I get the message box that connection has been lost. The server is deffinitely running cos I can log on again.

Share this post


Link to post
Share on other sites
tsolrm

the error is this :10053

Share this post


Link to post
Share on other sites
Jos

How are you testing this connection?

Is it within your own LAN with only a Switch inbetween or is there a LAT router in the the path?


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites
tsolrm

it's not a local server. Clients are miles away :oops:

Yes i have a router, i've set up port forwarding

Edited by tsolrm

Share this post


Link to post
Share on other sites
Jos

Maybe its your LAT router that timeout on the Session it has in its connection table. Are you sending Keep-Alives to indicate the session is still there?

You could try to run the script on 2 machines on your local LAN and see if that gives the same error.

Jos


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×