diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-07-14 11:43:17 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-07-14 11:43:17 +0000 |
commit | ccb1837a1481ed3d9048f2e4d0d5d6309f14d17d (patch) | |
tree | a0e0dea848b3af6f81cb72f5ff64a21d43214b1b /src/dns.cpp | |
parent | 45216ce4311f7dbe6ec7c8227152017449ea3336 (diff) |
Fix dns socket leak found in stable
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4383 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/dns.cpp')
-rw-r--r-- | src/dns.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/dns.cpp b/src/dns.cpp index e8b15c9bf..e3a32a745 100644 --- a/src/dns.cpp +++ b/src/dns.cpp @@ -702,6 +702,11 @@ void DNS::SetNS(const std::string &dnsserver) DNS::~DNS() { + if (this->myfd > -1) + { + log(DEBUG,"HA! An FD tried to sneak by unnoticed - freed it."); + dns_close(this->myfd); + } } bool DNS::ReverseLookup(const std::string &ip, bool ins) |