Skip to content
Permalink
Browse files

compress/zlib: fix error handling

[ upstream commit ff53baa9cc676249d1c5c514755d77e453a99b51 ]

Add missing return after setting the error status in case of
invalid flush_flag in the operation.
The issue was found by the coverity scan as the fin_flush variable,
not initialized in such case, was used later in the flow.

Coverity issue: 340859
Fixes: c7b436e ("compress/zlib: support burst enqueue/dequeue")

Signed-off-by: Adam Dybkowski <adamx.dybkowski@intel.com>
  • Loading branch information
Adam Dybkowski authored and kevintraynor committed Jul 24, 2019
1 parent f61b77c commit 7dedc1b9ed87e912f66b1cbba3c3108bfa489342
Showing with 1 addition and 0 deletions.
  1. +1 −0 drivers/compress/zlib/zlib_pmd.c
@@ -30,6 +30,7 @@ process_zlib_deflate(struct rte_comp_op *op, z_stream *strm)
default:
op->status = RTE_COMP_OP_STATUS_INVALID_ARGS;
ZLIB_PMD_ERR("Invalid flush value\n");
return;
}

if (unlikely(!strm)) {

0 comments on commit 7dedc1b

Please sign in to comment.
You can’t perform that action at this time.