|
2001-04-23
| ||
| 04:00 | • Ticket [218356ffff] Failed socket open prevents future attempts. status stil... artifact: 8980521ab8 user: dgp | |
|
2000-10-26
| ||
| 08:20 | • Closed ticket [218356ffff]. artifact: 3353794d98 user: welch | |
| 00:56 | • New ticket [218356ffff]. artifact: a04e61cc89 user: nobody | |
Failed socket open prevents future attempts.
Closed / Invalid218356ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 26 years ago
Descriptionplain2000-10-26 00:56:38
OriginalBugID: 4136 Bug
Version: 8.2.3
SubmitDate: '2000-02-07'
LastModified: '2000-02-07'
Severity: MED
Status: Closed
Submitter: techsupp
ChangedBy: hobbs
OS: Windows NT
OSVersion: Windows NT Service Pack 6a
Machine: Various Intel PC class machines
FixedDate: '2000-10-25'
ClosedDate: '2000-02-07'
Name:
Dwaine Gonyier
Extensions:
Binary tcl 8.2.3 distribution for Win32 from scriptics.com
ReproducibleScript:
proc opensock {addr} {
global sfp
while [catch {set sfp [socket $addr 19]} err] {
puts "Trying to open socket at [clock format [clock seconds]]"
puts "Error is $err"
}
}
ObservedBehavior:
This code is part of a script to be used in a test environment
where IP connections can be lost due to remote stations leaving
the network, etc. This proc is to be called when the existing
connection is lost, the idea being that the loop will retry forever
until the connection is reestablished. What I have found on WinNT
is that when the connection is lost and this proc is called, there
is a delay for the first pass through this loop because the socket
is actually trying to open. When it times out because the
remote host is not available, the loop start executing really
fast with no delay as though the socket call is giving up right
away, even if the remote host has since become available and
can be PINGed from another command prompt on the same station
executing this script.
I have used this same code with tcl 8.2.3
compiled on AIX 4.3.3 without any problems--the loop executes with
a delay for each pass as each socket attempt times out and once
the remote station becomes available, the connection is successfully
opened.
Under WinNt, I have added an after xxxx statement to the loop to
see if it is some type of spin condition, but it didn't help.
BTW, this problem can be simulated by trying to connect to a host IP
that doesn't exist.
DesiredBehavior:
Under win32, the socket command should actually try to connect
each time and not always immediately "give up" after the first
time a connection attempt fails.
The user didn't put {}s around the while condition, making it
essentially a constant of 1.
-- 02/07/2000 hobbs
welch Closed ticket [218356ffff].
[History diff]2000-10-26 08:20:08
dgp Ticket [218356ffff]: 4 changes
[History diff]2001-04-23 04:00:53
Log in (anonymous is fine) to add a comment.