app/crypto-perf: fix AEAD tests when AAD is zero
For AEAD algorithms, additional authenticated data (AAD)
can be passed, but it is optional, so its size can be zero.
Therefore, test can be run if no memory is allocated.
Fixes: f8be1786b1
("app/crypto-perf: introduce performance test application")
Cc: stable@dpdk.org
Signed-off-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
This commit is contained in:
parent
0091576132
commit
ad674b4d4a
@ -463,7 +463,7 @@ cperf_test_vector_get_dummy(struct cperf_options *options)
|
||||
break;
|
||||
}
|
||||
|
||||
if (aad_alloc) {
|
||||
if (aad_alloc && options->auth_aad_sz) {
|
||||
t_vec->aad.data = rte_malloc(NULL,
|
||||
options->auth_aad_sz, 16);
|
||||
if (t_vec->aad.data == NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user