Add Errno::ENETUNREACH to exception list in BasicNetworkResolver
Fixes #1621
This commit is contained in:
parent
529bcca927
commit
9a529cd294
|
@ -21,7 +21,7 @@ module Middleman
|
|||
# Array of Names
|
||||
def getnames(ip)
|
||||
resolver.getnames(ip.to_s).map(&:to_s)
|
||||
rescue Resolv::ResolvError, Errno::EADDRNOTAVAIL
|
||||
rescue Resolv::ResolvError, Errno::EADDRNOTAVAIL, Errno::ENETUNREACH
|
||||
[]
|
||||
end
|
||||
|
||||
|
@ -34,7 +34,7 @@ module Middleman
|
|||
# Array of ipaddresses
|
||||
def getaddresses(name)
|
||||
resolver.getaddresses(name.to_s).map(&:to_s)
|
||||
rescue Resolv::ResolvError, Errno::EADDRNOTAVAIL
|
||||
rescue Resolv::ResolvError, Errno::EADDRNOTAVAIL, Errno::ENETUNREACH
|
||||
[]
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue