Browse Source

Fix: add missing dialing counter decrement

Rod Hynes 9 years ago
parent
commit
938743cd6c
1 changed files with 4 additions and 0 deletions
  1. 4 0
      psiphon/server/tunnelServer.go

+ 4 - 0
psiphon/server/tunnelServer.go

@@ -1140,6 +1140,10 @@ func (sshClient *sshClient) runTunnel(
 			}
 
 			if remainingDialTimeout <= 0 {
+
+				// Release the dialing slot here since handleTCPChannel() won't be called.
+				sshClient.failedTCPPortForward()
+
 				sshClient.updateQualityMetricsWithRejectedDialingLimit()
 				sshClient.rejectNewChannel(
 					newPortForward.newChannel, ssh.Prohibited, "TCP port forward timed out before dialing")