diff options
| author | 2010-04-26 19:08:39 -0500 | |
|---|---|---|
| committer | 2010-04-26 19:08:43 -0500 | |
| commit | dc203f9f201e5a49677d3982f0b6c7d8610cc484 (patch) | |
| tree | bd8b210c43ff5ac16167e56d76589425a5428cab /src/dns.cpp | |
| parent | Add debug output for received DNS packets (diff) | |
| download | inspircd++-dc203f9f201e5a49677d3982f0b6c7d8610cc484.tar.gz inspircd++-dc203f9f201e5a49677d3982f0b6c7d8610cc484.tar.bz2 inspircd++-dc203f9f201e5a49677d3982f0b6c7d8610cc484.zip | |
Define comparator for irc::sockets::sockaddrs
This only compares IP/port, which ignores IPv6 flow information and
scope ID, which aren't important in testing for equality.
Diffstat (limited to 'src/dns.cpp')
| -rw-r--r-- | src/dns.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dns.cpp b/src/dns.cpp index ef9ac12bf..945e1fb15 100644 --- a/src/dns.cpp +++ b/src/dns.cpp @@ -578,7 +578,7 @@ DNSResult DNS::GetResult() * * -- Thanks jilles for pointing this one out. */ - if (memcmp(&from, &myserver, sizeof(irc::sockets::sockaddrs))) + if (from != myserver) { ServerInstance->Logs->Log("RESOLVER",DEBUG,"Got a result from the wrong server! Bad NAT or DNS forging attempt? '%s' != '%s'", from.str().c_str(), myserver.str().c_str()); |
