diff options
author | Ashwin Sekhar T K <asekhar@marvell.com> | 2021-07-12 21:00:49 +0530 |
---|---|---|
committer | Matias Elo <matias.elo@nokia.com> | 2021-07-14 08:33:46 +0300 |
commit | 0d75ce35e6f580c5eca5062256e8c4cb2baa01cb (patch) | |
tree | 0f296bbae7290cb169f55147a21c52b322665f1e | |
parent | 672957a38800119e1db9b490e1ac5a38f86041ef (diff) |
validation: pool: verify number of segments of reassembled packet
Verify that number of segments in the reassembled packet is equal to the
the number of packet buffers passed to reassemble call.
Signed-off-by: Ashwin Sekhar T K <asekhar@marvell.com>
Reviewed-by: Janne Peltonen <janne.peltonen@nokia.com>
-rw-r--r-- | test/validation/api/pool/pool.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/test/validation/api/pool/pool.c b/test/validation/api/pool/pool.c index 90a337b8c..d791063e2 100644 --- a/test/validation/api/pool/pool.c +++ b/test/validation/api/pool/pool.c @@ -1611,6 +1611,7 @@ static void test_packet_pool_ext_disassemble(void) pkt = odp_packet_reassemble(pool, pkt_buf, num_seg); CU_ASSERT_FATAL(pkt != ODP_PACKET_INVALID); + CU_ASSERT(odp_packet_num_segs(pkt) == (int)num_seg); pkt_tbl[i] = pkt; CU_ASSERT(odp_packet_len(pkt) == (pkt_len - (num_seg * 2))); |