summaryrefslogtreecommitdiff
path: root/lib/net.h
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2017-12-12 15:56:31 +0100
committerOndrej Zajicek (work) <santiago@crfreenet.org>2017-12-12 15:57:14 +0100
commitac48e72bf6f9f491824e2de59a035c93aab8f81b (patch)
treea6847c5a4996ff781235f79329e960ee6d2fcd85 /lib/net.h
parentcb5df823acdc54f94b0b85094cb59ac68c83c33a (diff)
Fix some minor issues
Diffstat (limited to 'lib/net.h')
-rw-r--r--lib/net.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/net.h b/lib/net.h
index 4b2077ae..69f00641 100644
--- a/lib/net.h
+++ b/lib/net.h
@@ -358,10 +358,10 @@ static inline int net_zero_roa6(const net_addr_roa6 *a)
{ return !a->pxlen && ip6_zero(a->prefix) && !a->max_pxlen && !a->asn; }
static inline int net_zero_flow4(const net_addr_flow4 *a)
-{ return !a->pxlen && ip4_zero(a->prefix) && !a->data; }
+{ return !a->pxlen && ip4_zero(a->prefix) && (a->length == sizeof(net_addr_flow4)); }
static inline int net_zero_flow6(const net_addr_flow6 *a)
-{ return !a->pxlen && ip6_zero(a->prefix) && !a->data; }
+{ return !a->pxlen && ip6_zero(a->prefix) && (a->length == sizeof(net_addr_flow6)); }
static inline int net_zero_mpls(const net_addr_mpls *a)
{ return !a->label; }