ddis 1.2.2 → 1.2.3
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/ddis.rb +6 -2
- metadata +1 -1
data/lib/ddis.rb
CHANGED
@@ -34,8 +34,12 @@ class DDis
|
|
34
34
|
hostname = nil
|
35
35
|
end
|
36
36
|
|
37
|
-
|
38
|
-
|
37
|
+
begin
|
38
|
+
@ping.host = ip
|
39
|
+
up = @ping.ping?
|
40
|
+
rescue
|
41
|
+
warn "Can't ping #{ip}" if @verbose
|
42
|
+
end
|
39
43
|
|
40
44
|
if up and ( hostname =~ /#{@unass}/ or hostname.nil? )
|
41
45
|
warn "#{ip} is up yet has an invalid hostname" if @verbose
|