提交 41300166 编写于 作者: M Matt Caswell

Fix Proxy where a timeout occurs waiting for both client and server

Reviewed-by: NRich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4305)
上级 6e5a853b
......@@ -297,8 +297,11 @@ sub clientstart
while( (!(TLSProxy::Message->end)
|| (defined $self->sessionfile()
&& (-s $self->sessionfile()) == 0))
&& $ctr < 10
&& (@ready = $sel->can_read(1))) {
&& $ctr < 10) {
if (!(@ready = $sel->can_read(1))) {
$ctr++;
next;
}
foreach my $hand (@ready) {
if ($hand == $server_sock) {
$server_sock->sysread($indata, 16384) or goto END;
......@@ -311,7 +314,7 @@ sub clientstart
$server_sock->syswrite($indata);
$ctr = 0;
} else {
$ctr++
die "Unexpected handle";
}
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册