app/test-crypto-perf: fix double allocation of memory
authorAnoob Joseph <anoob.joseph@caviumnetworks.com>
Mon, 10 Sep 2018 06:40:58 +0000 (12:10 +0530)
committerAkhil Goyal <akhil.goyal@nxp.com>
Tue, 25 Sep 2018 15:57:25 +0000 (17:57 +0200)
commitc61518ed86a02118322c9250be1797a58e3974ba
tree15dd0ac76c1e58bae6c5fabc97ad37af16229e58
parent3c78812b5082146f23af45784a04c37be9b90190
app/test-crypto-perf: fix double allocation of memory

The field, 'cipher_iv.data' is allocated twice when cipher is not null.
Ideally the allocation should depend only on the field
'cperf_options.cipher_iv_sz'. This will make sure this code path gets
valid for ciphers which doesn't require IV.

Fixes: 0fbd75a99fc9 ("cryptodev: move IV parameters to session")
Cc: stable@dpdk.org
Signed-off-by: Akash Saxena <akash.saxena@caviumnetworks.com>
Signed-off-by: Anoob Joseph <anoob.joseph@caviumnetworks.com>
Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
app/test-crypto-perf/cperf_test_vectors.c