app/crypto-perf: fix null dereference
authorSlawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
Fri, 10 Feb 2017 14:22:30 +0000 (15:22 +0100)
committerPablo de Lara <pablo.de.lara.guarch@intel.com>
Fri, 10 Feb 2017 15:06:04 +0000 (16:06 +0100)
commit559ef9201a9e28b75208b438a88b49b3085d664b
tree4384934fd9990d02eea8565e2b4306cdd0fcae10
parent7fb95c36028a8040b779e99eb87c231b086a0b2e
app/crypto-perf: fix null dereference

Dereferencing a pointer that might be null key_token when calling strstr.
Check if the pointer is null before.

Coverity issue: 141071
Fixes: f8be1786b1b8 ("app/crypto-perf: introduce performance test application")

Signed-off-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
app/test-crypto-perf/cperf_test_vector_parsing.c