diff options
author | Brian Behlendorf <[email protected]> | 2020-01-06 11:17:53 -0800 |
---|---|---|
committer | GitHub <[email protected]> | 2020-01-06 11:17:53 -0800 |
commit | bc9cef11fddfe8e6e240477084a49f4bad1fb4f3 (patch) | |
tree | c76ef6d1afa9d7d77d09a00b7d1355cabfc88637 /tests | |
parent | 581ca28169eaa2c3285057876f42bab3314051ad (diff) |
Fix QAT allocation failure return value
When qat_compress() fails to allocate the required contiguous memory
it mistakenly returns success. This prevents the fallback software
compression from taking over and (un)compressing the block.
Resolve the issue by correctly setting the local 'status' variable
on all exit paths. Furthermore, initialize it to CPA_STATUS_FAIL
to ensure qat_compress() always fails safe to guard against any
similar bugs in the future.
Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #9784
Closes #9788
Diffstat (limited to 'tests')
0 files changed, 0 insertions, 0 deletions