We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b459b70 commit d59ecb0Copy full SHA for d59ecb0
psa-crypto/src/operations/cipher.rs
@@ -32,7 +32,7 @@ fn crypt(
32
33
let mut output_length = 0;
34
let mut output_length_finish = 0;
35
- match (|| {
+ let mut inner_crypt = || {
36
Status::from(unsafe {
37
psa_crypto_sys::psa_cipher_set_iv(&mut operation, iv.as_ptr(), iv.len())
38
})
@@ -61,7 +61,8 @@ fn crypt(
61
.to_result()?;
62
63
Ok(())
64
- })() {
+ };
65
+ match inner_crypt() {
66
Ok(()) => (),
67
Err(x) => {
68
Status::from(unsafe { psa_crypto_sys::psa_cipher_abort(&mut operation) })
0 commit comments