optimizate: rename IP type to address family

This commit is contained in:
luwenpeng
2024-07-25 18:29:57 +08:00
parent b50f0c2c70
commit f43da9002b
10 changed files with 61 additions and 66 deletions

View File

@@ -411,7 +411,7 @@ int dumpfile_io_inject(struct dumpfile_io *handle, uint16_t thr_idx, struct pack
memset(&tuple, 0, sizeof(struct tuple6));
packet_get_innermost_tuple6(pkt, &tuple);
if (tuple.ip_type == IP_TYPE_V4)
if (tuple.addr_family == AF_INET)
{
inet_ntop(AF_INET, &tuple.src_addr.v4, src_addr, INET6_ADDRSTRLEN);
inet_ntop(AF_INET, &tuple.dst_addr.v4, dst_addr, INET6_ADDRSTRLEN);