tcp: fix byte tracker samples flush
Type: fix
Change-Id: I3b4cb8fc17387693d6ad6cdef004ca99cd56bc23
Signed-off-by: Florin Coras <fcoras@cisco.com>
(cherry picked from commit 92f190a802
)
This commit is contained in:

committed by
Damjan Marion

parent
56417fa946
commit
d4895f2fcf
@ -1093,6 +1093,19 @@ tcp_test_delivery (vlib_main_t * vm, unformat_input_t * input)
|
||||
TCP_TEST (rs->flags & TCP_BTS_IS_APP_LIMITED, "is app limited");
|
||||
TCP_TEST (tc->app_limited == 0, "app limited should be cleared");
|
||||
|
||||
/*
|
||||
* 9) test flush
|
||||
*/
|
||||
|
||||
tcp_bt_track_tx (tc);
|
||||
tc->snd_nxt += burst;
|
||||
|
||||
session_main.wrk[thread_index].last_vlib_time = 12;
|
||||
tcp_bt_track_tx (tc);
|
||||
tc->snd_nxt += burst;
|
||||
|
||||
tcp_bt_flush_samples (tc);
|
||||
|
||||
/*
|
||||
* Cleanup
|
||||
*/
|
||||
|
@ -544,6 +544,7 @@ tcp_bt_flush_samples (tcp_connection_t * tc)
|
||||
u32 *samples = 0, *si;
|
||||
|
||||
vec_validate (samples, pool_elts (bt->samples) - 1);
|
||||
vec_reset_length (samples);
|
||||
|
||||
/* *INDENT-OFF* */
|
||||
pool_foreach (bts, bt->samples, ({
|
||||
|
Reference in New Issue
Block a user