diff --git a/src/wallet/test/wallet_crypto_tests.cpp b/src/wallet/test/wallet_crypto_tests.cpp --- a/src/wallet/test/wallet_crypto_tests.cpp +++ b/src/wallet/test/wallet_crypto_tests.cpp @@ -30,8 +30,8 @@ nRounds, chKey, chIV); if (i != (int)WALLET_CRYPTO_KEY_SIZE) { - memory_cleanse(chKey, sizeof(chKey)); - memory_cleanse(chIV, sizeof(chIV)); + memory_cleanse(chKey, WALLET_CRYPTO_KEY_SIZE); + memory_cleanse(chIV, WALLET_CRYPTO_IV_SIZE); return false; } return true;