By using `okey_set_u128` we keep track of the address size and downstream plug-ins can distinguish the address family. Signed-off-by: Jeremy Sowden <jeremy@xxxxxxxxxx> --- filter/ulogd_filter_IP2HBIN.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/filter/ulogd_filter_IP2HBIN.c b/filter/ulogd_filter_IP2HBIN.c index 2711f9c3e12a..081616edbc51 100644 --- a/filter/ulogd_filter_IP2HBIN.c +++ b/filter/ulogd_filter_IP2HBIN.c @@ -157,15 +157,14 @@ static int interp_ip2hbin(struct ulogd_pluginstance *pi) if (pp_is_valid(inp, i)) { switch (convfamily) { case AF_INET: - okey_set_u32(&ret[i-START_KEY], - ntohl(ikey_get_u32(&inp[i]))); + okey_set_u32(&ret[i - START_KEY], + ntohl(ikey_get_u32(&inp[i]))); break; case AF_INET6: - okey_set_ptr(&ret[i-START_KEY], - (struct in6_addr *)ikey_get_u128(&inp[i])); + okey_set_u128(&ret[i - START_KEY], + ikey_get_u128(&inp[i])); break; default: - ; break; } } -- 2.40.1