mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
tcp hpts: initialize variable
Ensure that tv.tv_sec is zero in all code paths. Reported by: Coverity Scan CID: 1527724 Reviewed by: rscheff Sponsored by: Netflix, Inc. Differential Revision: https://reviews.freebsd.org/D44584 (cherry picked from commit aaaa01c0c858fd703194c6cbd515dd514574381f)
This commit is contained in:
parent
f3e2beb306
commit
60898a7cef
1 changed files with 1 additions and 1 deletions
|
|
@ -1650,6 +1650,7 @@ tcp_hpts_thread(void *ctx)
|
|||
* enough activity in the system that we don't need to
|
||||
* run as often (if we were not directly woken).
|
||||
*/
|
||||
tv.tv_sec = 0;
|
||||
if (hpts->p_direct_wake == 0) {
|
||||
counter_u64_add(hpts_back_tosleep, 1);
|
||||
if (hpts->p_on_queue_cnt >= conn_cnt_thresh) {
|
||||
|
|
@ -1674,7 +1675,6 @@ tcp_hpts_thread(void *ctx)
|
|||
* Directly woken most likely to reset the
|
||||
* callout time.
|
||||
*/
|
||||
tv.tv_sec = 0;
|
||||
tv.tv_usec = hpts->p_mysleep.tv_usec;
|
||||
}
|
||||
goto back_to_sleep;
|
||||
|
|
|
|||
Loading…
Reference in a new issue