tcp: remove useless assignment
In tcp_send_flag(),a4826ee04b
has replaced: th->doff = sizeof(*th) / 4; th->doff += OPT_MSS_LEN / 4; th->doff += (1 + OPT_WS_LEN) / 4; by optlen = OPT_MSS_LEN + 1 + OPT_WS_LEN; th->doff = (sizeof(*th) + optlen) / 4; but forgot to remove the useless "th->doff += (1 + OPT_WS_LEN) / 4;" Fixes:a4826ee04b
("tcp: Defer and coalesce all segments with no data (flags) to handler") Signed-off-by: Laurent Vivier <lvivier@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
parent
bae676a44e
commit
d902bb6288
1 changed files with 0 additions and 1 deletions
1
tcp.c
1
tcp.c
|
@ -1693,7 +1693,6 @@ static int tcp_send_flag(struct ctx *c, struct tcp_tap_conn *conn, int flags)
|
||||||
*(uint16_t *)data = htons(MIN(USHRT_MAX, mss));
|
*(uint16_t *)data = htons(MIN(USHRT_MAX, mss));
|
||||||
|
|
||||||
data += OPT_MSS_LEN - 2;
|
data += OPT_MSS_LEN - 2;
|
||||||
th->doff += OPT_MSS_LEN / 4;
|
|
||||||
|
|
||||||
conn->ws_to_tap = MIN(MAX_WS, tinfo.tcpi_snd_wscale);
|
conn->ws_to_tap = MIN(MAX_WS, tinfo.tcpi_snd_wscale);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue