aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/tcp/builtin_client.c
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2017-04-25 11:58:06 -0700
committerFlorin Coras <fcoras@cisco.com>2017-04-25 13:26:38 -0700
commit82b13a89a3cd436b9d3ed5538952508354ea65ba (patch)
tree27db5ce8e7c6fe7d4f771c0583da305b40762ef5 /src/vnet/tcp/builtin_client.c
parent11b8dbf78af49d270a0e72abe7dea73eec30d85f (diff)
Session/tcp coverity fixes
Change-Id: Ic5467df16e870b49c49678b1dbb40f4a2390b3c9 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/vnet/tcp/builtin_client.c')
-rw-r--r--src/vnet/tcp/builtin_client.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/vnet/tcp/builtin_client.c b/src/vnet/tcp/builtin_client.c
index 276beb216d2..32d69a9633e 100644
--- a/src/vnet/tcp/builtin_client.c
+++ b/src/vnet/tcp/builtin_client.c
@@ -56,6 +56,9 @@ send_test_chunk (tclient_main_t * tm, session_t * s)
session_fifo_event_t evt;
static int serial_number = 0;
int rv;
+
+ ASSERT (vec_len (test_data) > 0);
+
test_buf_offset = s->bytes_sent % vec_len (test_data);
bytes_this_chunk = vec_len (test_data) - test_buf_offset;