[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] crypto/block-luks: always set splitkeylen to 0
From: |
Patrick Venture |
Subject: |
[PATCH] crypto/block-luks: always set splitkeylen to 0 |
Date: |
Wed, 7 Sep 2022 09:21:25 -0700 |
This was caught by a sanitized build, that was perhaps oversensitive.
Signed-off-by: Patrick Venture <venture@google.com>
---
crypto/block-luks.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/crypto/block-luks.c b/crypto/block-luks.c
index f62be6836b..8633fb7e9f 100644
--- a/crypto/block-luks.c
+++ b/crypto/block-luks.c
@@ -729,7 +729,7 @@ qcrypto_block_luks_store_key(QCryptoBlock *block,
QCryptoBlockLUKS *luks = block->opaque;
QCryptoBlockLUKSKeySlot *slot;
g_autofree uint8_t *splitkey = NULL;
- size_t splitkeylen;
+ size_t splitkeylen = 0;
g_autofree uint8_t *slotkey = NULL;
g_autoptr(QCryptoCipher) cipher = NULL;
g_autoptr(QCryptoIVGen) ivgen = NULL;
@@ -901,7 +901,7 @@ qcrypto_block_luks_load_key(QCryptoBlock *block,
QCryptoBlockLUKS *luks = block->opaque;
const QCryptoBlockLUKSKeySlot *slot;
g_autofree uint8_t *splitkey = NULL;
- size_t splitkeylen;
+ size_t splitkeylen = 0;
g_autofree uint8_t *possiblekey = NULL;
int rv;
g_autoptr(QCryptoCipher) cipher = NULL;
@@ -1147,7 +1147,7 @@ qcrypto_block_luks_erase_key(QCryptoBlock *block,
QCryptoBlockLUKS *luks = block->opaque;
QCryptoBlockLUKSKeySlot *slot;
g_autofree uint8_t *garbagesplitkey = NULL;
- size_t splitkeylen;
+ size_t splitkeylen = 0;
size_t i;
Error *local_err = NULL;
int ret;
--
2.37.2.789.g6183377224-goog
- [PATCH] crypto/block-luks: always set splitkeylen to 0,
Patrick Venture <=