Correct use of select and expand the listen queue for TCP Servers

git-svn-id: file:///home/svn/framework3/trunk@12484 4d416f70-5f16-0410-b530-b9f4589650da
unstable
HD Moore 2011-04-30 18:08:52 +00:00
parent 140a304032
commit 39cab9b076
3 changed files with 3 additions and 3 deletions

View File

@ -134,7 +134,7 @@ class Client
begin
ssl.accept_nonblock
rescue ::OpenSSL::SSL::ReadAgain, ::OpenSSL::SSL::WriteAgain, ::OpenSSL::SSL::SSLError
select(nil, nil, nil, 0.25)
::IO.select(nil, nil, nil, 0.25)
retry
end
end

View File

@ -206,7 +206,7 @@ class Rex::Socket::Comm::Local
# If a server TCP instance is being created...
if (param.server?)
sock.listen(128)
sock.listen(256)
if (param.bare? == false)
klass = Rex::Socket::TcpServer

View File

@ -64,7 +64,7 @@ module Rex::Socket::SslTcpServer
begin
ssl.accept_nonblock
rescue ::OpenSSL::SSL::ReadAgain, ::OpenSSL::SSL::WriteAgain, ::OpenSSL::SSL::SSLError
select(nil, nil, nil, 0.25)
::IO.select(nil, nil, nil, 0.25)
retry
end
end