Fixes #605 by re-raising the correct exception class

git-svn-id: file:///home/svn/framework3/trunk@7701 4d416f70-5f16-0410-b530-b9f4589650da
unstable
HD Moore 2009-12-04 18:38:59 +00:00
parent 8a186921e7
commit 9b2d5fcd24
1 changed files with 7 additions and 0 deletions

View File

@ -107,7 +107,14 @@ class Socket
# Creates a TCP client channel.
#
def create_tcp_client(params)
begin
return SocketSubsystem::TcpClientChannel.open(client, params)
rescue ::Rex::Post::Meterpreter::RequestError => e
if(e.result == 10061)
raise ::Rex::ConnectionError.new
end
raise e
end
end
#