Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Linux: Fix uninitialized variable usage in zio_do_crypt_data()
Coverity complained about this. An error from `hkdf_sha512()` before uio initialization will cause pointers to uninitalized memory to be passed to `zio_crypt_destroy_uio()`. This is a regression that was introduced by cf63739. Interestingly, this never affected FreeBSD, since the FreeBSD version never had that patch ported. Since moving uio initialization to the top of this function would slow down the qat_crypt() path, we only move the `memset()` calls to the top of the function. This is sufficient to fix this problem. Signed-off-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
- Loading branch information