aboutsummaryrefslogtreecommitdiff
path: root/include/salticidae/netaddr.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/salticidae/netaddr.h')
-rw-r--r--include/salticidae/netaddr.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/salticidae/netaddr.h b/include/salticidae/netaddr.h
index 1b53dff..eabb5da 100644
--- a/include/salticidae/netaddr.h
+++ b/include/salticidae/netaddr.h
@@ -84,7 +84,11 @@ struct NetAddr {
bool operator==(const NetAddr &other) const {
return ip == other.ip && port == other.port;
}
-
+
+ bool operator!=(const NetAddr &other) const {
+ return ip != other.ip || port != other.port;
+ }
+
operator std::string() const {
struct in_addr in;
in.s_addr = ip;