mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-05 16:00:05 +01:00
Wipe buffers to be sure padding is always empty.
Detected by valgrind as writing unitialized data.
This commit is contained in:
@@ -47,6 +47,7 @@ int crypt_benchmark(struct crypt_device *cd,
|
||||
r = -ENOMEM;
|
||||
if (posix_memalign(&buffer, crypt_getpagesize(), buffer_size))
|
||||
goto out;
|
||||
memset(buffer, 0, buffer_size);
|
||||
|
||||
r = crypt_cipher_ivsize(cipher, cipher_mode);
|
||||
if (r >= 0 && iv_size != (size_t)r) {
|
||||
|
||||
Reference in New Issue
Block a user