Opened on Nov 26, 2009 at 7:04:40 AM
Closed on May 17, 2010 at 6:05:56 PM
Last modified on Jul 25, 2010 at 5:47:08 PM
#1310 closed Feature Request (Fixed)
TCPConnect Timeout
| Reported by: | Proggy | Owned by: | |
|---|---|---|---|
| Milestone: | Future Release | Component: | AutoIt |
| Version: | Severity: | None | |
| Keywords: | Cc: |
Description
I'd like the TCPconnect() function to have a parameter where you can specify the timeout before stopping the connection attempt.
The current TCPConnect function is as follows:
TCPConnect(IPAddr,port)
If IPAddr or port is unavailable/closed then the connection attempt only times out after 5-10 secs. What I want is the ability to set the timeout (in ms)
ex:
TCPConnect(IPAddr,port[,timeout])
Thanks
Hawk
Attachments (0)
Change History (8)
follow-up: 5 comment:2 by , on May 13, 2010 at 7:38:04 AM
Ther is a fix in the pipe that is going to do the same timeout as for other TCP...() functions.
Is that OK?
comment:3 by , on May 17, 2010 at 6:05:56 PM
| Resolution: | → Fixed |
|---|---|
| Status: | new → closed |
Fixed with ticket #1573
follow-up: 6 comment:5 by , on Jul 23, 2010 at 10:07:17 AM
Replying to Jpm:
Ther is a fix in the pipe that is going to do the same timeout as for other TCP...() functions.
Is that OK?
I don´t understand what you meaning with this sentence. I have the problem too and i don´t know the resolution...
mfg bjoerni
follow-up: 7 comment:6 by , on Jul 25, 2010 at 12:55:10 PM
Replying to bjoern@…:
Replying to Jpm:
Ther is a fix in the pipe that is going to do the same timeout as for other TCP...() functions.
Is that OK?
I don´t understand what you meaning with this sentence. I have the problem too and i don´t know the resolution...
mfg bjoerni
I mean that today we have already a timeout defined by Opt("TCPTimeOUT", ...) which is working with other TCP...() functions.
What I did is to use the same timeout for TCPConnect() too.
follow-up: 8 comment:7 by , on Jul 25, 2010 at 1:39:05 PM
Replying to Jpm:
Replying to bjoern@…:
Replying to Jpm:
Ther is a fix in the pipe that is going to do the same timeout as for other TCP...() functions.
Is that OK?
I don´t understand what you meaning with this sentence. I have the problem too and i don´t know the resolution...
mfg bjoerni
I mean that today we have already a timeout defined by Opt("TCPTimeOUT", ...) which is working with other TCP...() functions.
What I did is to use the same timeout for TCPConnect() too.
so you plan to implement this in the future? or is it already included in the beta?
comment:8 by , on Jul 25, 2010 at 5:47:08 PM
Replying to anonymous:
Replying to Jpm:
Replying to bjoern@…:
Replying to Jpm:
Ther is a fix in the pipe that is going to do the same timeout as for other TCP...() functions.
Is that OK?
I don´t understand what you meaning with this sentence. I have the problem too and i don´t know the resolution...
mfg bjoerni
I mean that today we have already a timeout defined by Opt("TCPTimeOUT", ...) which is working with other TCP...() functions.
What I did is to use the same timeout for TCPConnect() too.
so you plan to implement this in the future? or is it already included in the beta?
Yes, it is in the next beta or Release

i also have same problem
The result: Connect Failed! time-consuming: 20.9968sec
====
Opt("TCPTimeout",10)
Global $out_txt
TCPStartup()
$iBeginTime = TimerInit()
$socket = TCPConnect("192.168.1.18", 8080)
If $socket <> -1 Then
Else
EndIf
TCPCloseSocket($socket)
ConsoleWrite($out_txt & @CRLF)
MsgBox(0, "", $out_txt)