1
0
Fork 0
mirror of https://passt.top/passt synced 2025-05-21 00:35:34 +02:00

udp: Remove redundant udp_at_sidx() call in udp_tap_handler()

We've already have a pointer to the UDP flow in variable uflow, we can just
re-use it.

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-04-01 19:57:08 +11:00 committed by Stefano Brivio
parent 3d41e4d838
commit 8aa2d90c8d

2
udp.c
View file

@ -907,7 +907,7 @@ int udp_tap_handler(const struct ctx *c, uint8_t pif,
}
toside = flowside_at_sidx(tosidx);
s = udp_at_sidx(tosidx)->s[tosidx.sidei];
s = uflow->s[tosidx.sidei];
ASSERT(s >= 0);
pif_sockaddr(c, &to_sa, &sl, topif, &toside->eaddr, toside->eport);