From d9969c102df9ea4ef11a95f94f40c63d9d12b354 Mon Sep 17 00:00:00 2001 From: baoyinshan Date: Fri, 17 Apr 2020 20:24:14 +0800 Subject: [PATCH] fix bug of compare operator Signed-off-by: baoyinshan --- certain/network/InetAddr.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/certain/network/InetAddr.h b/certain/network/InetAddr.h index 4fccc8e..523ea42 100644 --- a/certain/network/InetAddr.h +++ b/certain/network/InetAddr.h @@ -45,7 +45,7 @@ struct InetAddr_t return tAddr.sin_port < tOtherAddr.sin_port; } - return true; + return false; } InetAddr_t() @@ -85,7 +85,7 @@ struct InetAddr_t return acBuffer; } - uint32_t GetNetOrderIP() + uint32_t GetNetOrderIP() const { return tAddr.sin_addr.s_addr; }