summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/resolv-replace.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/resolv-replace.rb b/lib/resolv-replace.rb
index ff34f90db46..3e28a843fd9 100644
--- a/lib/resolv-replace.rb
+++ b/lib/resolv-replace.rb
@@ -19,7 +19,7 @@ class TCPSocket < IPSocket
alias original_resolv_initialize initialize
# :startdoc:
def initialize(host, serv, *rest)
- rest[0] = IPSocket.getaddress(rest[0]) unless rest.empty?
+ rest[0] = IPSocket.getaddress(rest[0]) if rest[0]
original_resolv_initialize(IPSocket.getaddress(host), serv, *rest)
end
end