From 7398f9aa67243a3e1d7fc4e22647865f87c8b203 Mon Sep 17 00:00:00 2001 From: Andrew Stitcher Date: Mon, 21 May 2012 22:51:16 +0000 Subject: QPID-4011: TestIsLocalHost unit_test fails with if machine name resolves to loopback address Oops - ntohl() can be a macro so specifying ::ntohl() can fail in optimised builds. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1341246 13f79535-47bb-0310-9956-ffa450edef68 --- qpid/cpp/src/qpid/sys/posix/SystemInfo.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'qpid/cpp/src') diff --git a/qpid/cpp/src/qpid/sys/posix/SystemInfo.cpp b/qpid/cpp/src/qpid/sys/posix/SystemInfo.cpp index c57f784058..007d0773fc 100755 --- a/qpid/cpp/src/qpid/sys/posix/SystemInfo.cpp +++ b/qpid/cpp/src/qpid/sys/posix/SystemInfo.cpp @@ -65,7 +65,7 @@ static const string TCP("tcp"); // Test IPv4 address for loopback inline bool IN_IS_ADDR_LOOPBACK(const ::in_addr* a) { - return ((::ntohl(a->s_addr) & 0xff000000) == 0x7f000000); + return ((ntohl(a->s_addr) & 0xff000000) == 0x7f000000); } inline bool isLoopback(const ::sockaddr* addr) { -- cgit v1.2.1