Files
mirror_zfs/module
Jorgen Lundman 4b629d04a5 Avoid calling rw_destroy() on uninitialized rwlock
First the function `memset(&key, 0, ...)` but
any call to "goto error;" would call zio_crypt_key_destroy(key) which
calls `rw_destroy()`. The `rw_init()` is moved up to be right after the
memset. This way the rwlock can be released.

The ctx does allocate memory, but that is handled by the memset to 0
and icp skips NULL ptrs.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Signed-off-by: Jorgen Lundman <lundman@lundman.net>
Closes #13976
2022-10-05 17:07:50 -07:00
..
2022-09-27 12:36:58 -07:00
2022-09-27 16:44:13 -07:00
2022-08-12 14:20:25 -07:00
2022-09-13 16:40:10 -07:00
2022-09-13 16:40:10 -07:00