minor: whitespace fixes
This commit is contained in:
parent
93b2f3da9b
commit
bf9bb83b6d
|
@ -101,12 +101,12 @@ module Mongo
|
|||
rescue ConnectionFailure, OperationFailure, OperationTimeout, SocketError, SystemCallError, IOError => ex
|
||||
@connection.log(:warn, "Attempted connection to node #{host_string} raised " +
|
||||
"#{ex.class}: #{ex.message}")
|
||||
|
||||
|
||||
# Socket may already be nil from issuing command
|
||||
if @socket && !@socket.closed?
|
||||
@socket.close
|
||||
end
|
||||
|
||||
|
||||
return nil
|
||||
end
|
||||
|
||||
|
|
|
@ -224,10 +224,10 @@ module Mongo
|
|||
end
|
||||
|
||||
if @pids[socket] != Process.pid
|
||||
@pids[socket] = nil
|
||||
@sockets.delete(socket)
|
||||
socket.close if socket
|
||||
checkout_new_socket
|
||||
@pids[socket] = nil
|
||||
@sockets.delete(socket)
|
||||
socket.close if socket
|
||||
checkout_new_socket
|
||||
else
|
||||
@checked_out << socket
|
||||
@threads_to_sockets[Thread.current] = socket
|
||||
|
|
Loading…
Reference in New Issue