X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fdns.cpp;h=28ceac68948f1bfd273f82db9b90936cba1cf78e;hb=21f9acdb6c5c35b26d926f75845135f16c3c54e9;hp=c8e465de8815e70548e7ef90a2744e3eb74bef3a;hpb=b0e07f5e9c393876940b3a22e888d702496258d8;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/dns.cpp b/src/dns.cpp index c8e465de8..28ceac689 100644 --- a/src/dns.cpp +++ b/src/dns.cpp @@ -11,6 +11,8 @@ * --------------------------------------------------- */ +/* $Core: libIRCDasyncdns */ + /* dns.cpp - Nonblocking DNS functions. Very very loosely based on the firedns library, @@ -108,32 +110,32 @@ class DNSRequest int SendRequests(const DNSHeader *header, const int length, QueryType qt); }; -class CacheTimer : public InspTimer +class CacheTimer : public Timer { private: InspIRCd* ServerInstance; DNS* dns; public: CacheTimer(InspIRCd* Instance, DNS* thisdns) - : InspTimer(3600, Instance->Time(), true), ServerInstance(Instance), dns(thisdns) { } + : Timer(3600, Instance->Time(), true), ServerInstance(Instance), dns(thisdns) { } - virtual void Tick(time_t TIME) + virtual void Tick(time_t) { dns->PruneCache(); } }; -class RequestTimeout : public InspTimer +class RequestTimeout : public Timer { InspIRCd* ServerInstance; DNSRequest* watch; int watchid; public: - RequestTimeout(unsigned long n, InspIRCd* SI, DNSRequest* watching, int id) : InspTimer(n, time(NULL)), ServerInstance(SI), watch(watching), watchid(id) + RequestTimeout(unsigned long n, InspIRCd* SI, DNSRequest* watching, int id) : Timer(n, time(NULL)), ServerInstance(SI), watch(watching), watchid(id) { } - void Tick(time_t TIME) + void Tick(time_t) { if (ServerInstance->Res->requests[watchid] == watch) { @@ -1018,7 +1020,7 @@ Resolver::Resolver(InspIRCd* Instance, const std::string &source, QueryType qt, } /** Called when an error occurs */ -void Resolver::OnError(ResolverError e, const std::string &errormessage) +void Resolver::OnError(ResolverError, const std::string&) { /* Nothing in here */ } @@ -1041,7 +1043,7 @@ Module* Resolver::GetCreator() } /** Process a socket read event */ -void DNS::HandleEvent(EventType et, int errornum) +void DNS::HandleEvent(EventType, int) { /* Fetch the id and result of the next available packet */ int resultnum = 0;