flow_control: slighly simpler logic
parent
0c68821bbc
commit
aad803ee04
|
@ -15,8 +15,7 @@ function do_ssl_handshake(client)
|
|||
queue_encrypted_bytes(client, buf)
|
||||
elseif !bio_should_retry(client.wbio)
|
||||
return -1
|
||||
end
|
||||
if n <= 0
|
||||
else
|
||||
break
|
||||
end
|
||||
end
|
||||
|
@ -44,8 +43,9 @@ function do_encrypt(client)
|
|||
queue_encrypted_bytes(client, buf)
|
||||
elseif !bio_should_retry(client.wbio)
|
||||
return -1
|
||||
else
|
||||
break
|
||||
end
|
||||
n > 0 || break
|
||||
end
|
||||
end
|
||||
if status in (SSL_ERROR, SSL_SYSCALL)
|
||||
|
@ -97,8 +97,9 @@ function on_read_cb(client, buffer)
|
|||
queue_encrypted_bytes(client, buf)
|
||||
elseif !bio_should_retry(client.wbio)
|
||||
return -1
|
||||
else
|
||||
break
|
||||
end
|
||||
n < 0 && break
|
||||
end
|
||||
end
|
||||
if status in (SSL_ERROR, SSL_SYSCALL)
|
||||
|
|
Loading…
Reference in New Issue