test/reorder: fix freeing mbuf twice
authorReshma Pattan <reshma.pattan@intel.com>
Fri, 4 May 2018 10:47:06 +0000 (11:47 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Sun, 13 May 2018 21:19:51 +0000 (23:19 +0200)
commitecd867faa860b41a154b3e24f6ea4536562234ab
treeda8328574a36e6d8600b44ad354e0ba2f57fdd88
parentc981825388f81fb191f5a79c80adf0fdb074e584
test/reorder: fix freeing mbuf twice

mbufs are being freed twice in error, once in rte_mempool_put_bulk()
and then in rte_reorder_free(). Refactor the code so that we use
rte_reorder_free() to free mbufs in the reorder buffer, and use
rte_pktmbuf_free() to free any unused or drained mbufs.

Fixes: d0c9b58d71 ("app/test: new reorder unit test")
Cc: stable@dpdk.org
Signed-off-by: Reshma Pattan <reshma.pattan@intel.com>
Reviewed-by: David Hunt <david.hunt@intel.com>
test/test/test_reorder.c