Skip to content

Commit

Permalink
Incorporate MRI's fix for #3886.
Browse files Browse the repository at this point in the history
  • Loading branch information
headius committed Nov 8, 2016
1 parent 477eb70 commit 9187c5e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/ruby/stdlib/resolv.rb
Expand Up @@ -576,13 +576,13 @@ def make_tcp_requester(host, port) # :nodoc:
def extract_resources(msg, name, typeclass) # :nodoc:
if typeclass < Resource::ANY
n0 = Name.create(name)
msg.each_answer {|n, ttl, data|
msg.each_resource {|n, ttl, data|
yield data if n0 == n
}
end
yielded = false
n0 = Name.create(name)
msg.each_answer {|n, ttl, data|
msg.each_resource {|n, ttl, data|
if n0 == n
case data
when typeclass
Expand All @@ -594,7 +594,7 @@ def extract_resources(msg, name, typeclass) # :nodoc:
end
}
return if yielded
msg.each_answer {|n, ttl, data|
msg.each_resource {|n, ttl, data|
if n0 == n
case data
when typeclass
Expand Down

0 comments on commit 9187c5e

Please sign in to comment.