1
0
Fork 0
mirror of https://passt.top/passt synced 2025-08-13 02:33:12 +02:00

tcp: More type safety for tcp_flow_migrate_target_ext()

tcp_flow_migrate_target_ext() takes a raw union flow *, although it is TCP
specific, and requires a FLOW_TYPE_TCP entry.  Our usual convention is that
such functions should take a struct tcp_tap_conn * instead.  Convert it to
do so.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
David Gibson 2025-02-18 19:59:21 +11:00 committed by Stefano Brivio
commit e56c8038fc
3 changed files with 5 additions and 6 deletions

2
flow.c
View file

@ -1106,7 +1106,7 @@ int flow_migrate_target(struct ctx *c, const struct migrate_stage *stage,
repair_flush(c);
for (i = 0; i < count; i++) {
rc = tcp_flow_migrate_target_ext(c, flowtab + i, fd);
rc = tcp_flow_migrate_target_ext(c, &flowtab[i].tcp, fd);
if (rc) {
debug("Migration data failure at flow %u: %s, abort",
i, strerror_(-rc));