diff options
author | Aloys Augustin <aloaugus@cisco.com> | 2020-04-01 19:50:17 +0200 |
---|---|---|
committer | Andrew Yourtchenko <ayourtch@gmail.com> | 2020-08-13 10:39:40 +0000 |
commit | 3c3d43b950778277a6733efedef39970bacf5c24 (patch) | |
tree | 4b6c1c1d3e4e66ff009e158d44fca3f0ee0e2a63 /src/vnet | |
parent | faab8a17b881b743aa56d8a9dd9cde83a04dd890 (diff) |
session: fix fifos display
This prevents a crash with quic listeners, and enables the display
of udp fifo status.
Change-Id: Ib9f48818ee3e51a3fa43ad8ab175e8aa7750df8f
Type: fix
Signed-off-by: Aloys Augustin <aloaugus@cisco.com>
(cherry picked from commit 6eef40bce3f5ae2b06ba75d5b4cf32f168a801e4)
Diffstat (limited to 'src/vnet')
-rwxr-xr-x | src/vnet/session/session_cli.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/vnet/session/session_cli.c b/src/vnet/session/session_cli.c index 2dc9b4903d6..d4b510d3451 100755 --- a/src/vnet/session/session_cli.c +++ b/src/vnet/session/session_cli.c @@ -67,13 +67,10 @@ format_session (u8 * s, va_list * args) if (verbose == 1) { - u8 post_accept = ss->session_state >= SESSION_STATE_ACCEPTING; - u8 hasf = post_accept - || session_transport_service_type (ss) == TRANSPORT_SERVICE_CL; u32 rxf, txf; - rxf = hasf ? svm_fifo_max_dequeue (ss->rx_fifo) : 0; - txf = hasf ? svm_fifo_max_dequeue (ss->tx_fifo) : 0; + rxf = ss->rx_fifo ? svm_fifo_max_dequeue (ss->rx_fifo) : 0; + txf = ss->tx_fifo ? svm_fifo_max_dequeue (ss->tx_fifo) : 0; str = format (0, "%-10u%-10u", rxf, txf); } |