1
0
mirror of https://passt.top/passt synced 2024-12-22 05:35:23 +00:00

tcp: Remove redundant initialisation of iov[TCP_IOV_ETH].iov_base

This initialisation for IPv4 flags buffers is redundant with the very next
line which sets both iov_base and iov_len.

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 2024-09-12 16:59:39 +10:00 committed by Stefano Brivio
parent 6b38f07239
commit 1f414ed8f0

View File

@ -168,7 +168,6 @@ void tcp_sock4_iov_init(const struct ctx *c)
iov = tcp4_l2_flags_iov[i];
iov[TCP_IOV_TAP] = tap_hdr_iov(c, &tcp4_flags_tap_hdr[i]);
iov[TCP_IOV_ETH].iov_base = &tcp4_eth_src;
iov[TCP_IOV_ETH] = IOV_OF_LVALUE(tcp4_eth_src);
iov[TCP_IOV_IP] = IOV_OF_LVALUE(tcp4_flags_ip[i]);
iov[TCP_IOV_PAYLOAD].iov_base = &tcp4_flags[i];