Add tests for BoostAsioToCNetAddr

This commit is contained in:
Wladimir J. van der Laan
2014-04-28 15:23:29 +02:00
parent fdbd7075ca
commit 21bf3d257b
3 changed files with 21 additions and 2 deletions

View File

@@ -359,8 +359,7 @@ void ErrorReply(std::ostream& stream, const Object& objError, const Value& id)
stream << HTTPReply(nStatus, strReply, false) << std::flush;
}
// Convert boost::asio address to CNetAddr
static CNetAddr BoostAsioToCNetAddr(boost::asio::ip::address address)
CNetAddr BoostAsioToCNetAddr(boost::asio::ip::address address)
{
CNetAddr netaddr;
// Make sure that IPv4-compatible and IPv4-mapped IPv6 addresses are treated as IPv4 addresses