TCP RACK: don't log an uninitialized value

reduce is uninitialized, if the code path for logging is reached via
goto old_method;.

Reviewed by:		rrs, Peter Lei
CID:			1557359
MFC after:		1 week
Sponsored by:		Netflix, Inc.
Differential Revision:	https://reviews.freebsd.org/D48346
This commit is contained in:
Michael Tuexen 2025-01-08 23:15:54 +01:00
parent 2c48a8f161
commit 4c89d59e0c

View file

@ -17474,7 +17474,7 @@ rack_get_pacing_delay(struct tcp_rack *rack, struct tcpcb *tp, uint32_t len, str
* the peer to have a gap in data sending.
*/
uint64_t cwnd, tr_perms = 0;
int32_t reduce = 0;
int32_t reduce;
old_method:
/*
@ -17511,7 +17511,8 @@ rack_get_pacing_delay(struct tcp_rack *rack, struct tcpcb *tp, uint32_t len, str
slot -= reduce;
} else
slot = 0;
}
} else
reduce = 0;
slot *= HPTS_USEC_IN_MSEC;
if (rack->rc_pace_to_cwnd) {
uint64_t rate_wanted = 0;