From 16f5586bb811dd344c3bbeadc88f30568986adbc Mon Sep 17 00:00:00 2001 From: David Gibson Date: Fri, 22 Jul 2022 15:31:18 +1000 Subject: Make substructures for IPv4 and IPv6 specific context information The context structure contains a batch of fields specific to IPv4 and to IPv6 connectivity. Split those out into a sub-structure. This allows the conf_ip4() and conf_ip6() functions, which take the entire context but touch very little of it, to be given more specific parameters, making it clearer what it affects without stepping through the code. Signed-off-by: David Gibson --- passt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'passt.c') diff --git a/passt.c b/passt.c index 5d0b3cd..0113002 100644 --- a/passt.c +++ b/passt.c @@ -363,7 +363,7 @@ int main(int argc, char **argv) if ((!c.no_udp && udp_init(&c)) || (!c.no_tcp && tcp_init(&c))) exit(EXIT_FAILURE); - proto_update_l2_buf(c.mac_guest, c.mac, &c.addr4); + proto_update_l2_buf(c.mac_guest, c.mac, &c.ip4.addr); if (c.ifi4 && !c.no_dhcp) dhcp_init(); -- cgit v1.2.3