Software /
code /
prosody
Comparison
net/dns.lua @ 2742:6c0a081cd766
net.dns: Trailing whitespace
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Fri, 05 Mar 2010 18:33:28 +0000 |
parent | 2741:fcd30b72c50c |
child | 3049:e54774bd73a7 |
comparison
equal
deleted
inserted
replaced
2741:fcd30b72c50c | 2742:6c0a081cd766 |
---|---|
530 end | 530 end |
531 end | 531 end |
532 if not self.server or #self.server == 0 then | 532 if not self.server or #self.server == 0 then |
533 -- TODO log warning about no nameservers, adding opendns servers as fallback | 533 -- TODO log warning about no nameservers, adding opendns servers as fallback |
534 self:addnameserver("208.67.222.222"); | 534 self:addnameserver("208.67.222.222"); |
535 self:addnameserver("208.67.220.220") ; | 535 self:addnameserver("208.67.220.220"); |
536 end | 536 end |
537 else -- posix | 537 else -- posix |
538 local resolv_conf = io.open("/etc/resolv.conf"); | 538 local resolv_conf = io.open("/etc/resolv.conf"); |
539 if resolv_conf then | 539 if resolv_conf then |
540 for line in resolv_conf:lines() do | 540 for line in resolv_conf:lines() do |
799 if coroutine.status(co) == "suspended" then coroutine.resume(co); end | 799 if coroutine.status(co) == "suspended" then coroutine.resume(co); end |
800 end | 800 end |
801 set(self.wanted, q.class, q.type, q.name, nil); | 801 set(self.wanted, q.class, q.type, q.name, nil); |
802 end | 802 end |
803 end | 803 end |
804 end | 804 end |
805 | 805 |
806 return response; | 806 return response; |
807 end | 807 end |
808 | 808 |
809 function resolver:cancel(data) | 809 function resolver:cancel(data) |