Running txonly mode can crash with "--txpkts=20,470". copy_len should be properly adjusted.
Fixes: af75078fece3 ("first public release") Cc: sta...@dpdk.org Signed-off-by: Yongseok Koh <ys...@mellanox.com> --- app/test-pmd/txonly.c | 1 + 1 file changed, 1 insertion(+) diff --git a/app/test-pmd/txonly.c b/app/test-pmd/txonly.c index 309c73893..4ce4d61cc 100644 --- a/app/test-pmd/txonly.c +++ b/app/test-pmd/txonly.c @@ -104,6 +104,7 @@ copy_buf_to_pkt_segs(void* buf, unsigned len, struct rte_mbuf *pkt, buf = ((char*) buf + copy_len); seg = seg->next; seg_buf = rte_pktmbuf_mtod(seg, char *); + copy_len = seg->data_len; } rte_memcpy(seg_buf, buf, (size_t) len); } -- 2.11.0