net/dns.lua

changeset 2301
8a01b0898679
parent 2300
e182b5029ef2
child 2387
92264ee3a0e4
equal deleted inserted replaced
2300:e182b5029ef2 2301:8a01b0898679
743 743
744 if not next(queries) then self.active[response.header.id] = nil; end 744 if not next(queries) then self.active[response.header.id] = nil; end
745 if not next(self.active) then self:closeall(); end 745 if not next(self.active) then self:closeall(); end
746 746
747 -- was the query on the wanted list? 747 -- was the query on the wanted list?
748 local q = response.question; 748 local q = response.question[1];
749 local cos = get(self.wanted, q.class, q.type, q.name); 749 local cos = get(self.wanted, q.class, q.type, q.name);
750 if cos then 750 if cos then
751 for co in pairs(cos) do 751 for co in pairs(cos) do
752 set(self.yielded, co, q.class, q.type, q.name, nil); 752 set(self.yielded, co, q.class, q.type, q.name, nil);
753 if coroutine.status(co) == "suspended" then coroutine.resume(co); end 753 if coroutine.status(co) == "suspended" then coroutine.resume(co); end

mercurial