aboutsummaryrefslogtreecommitdiffstats
path: root/src/s2k/s2k.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/s2k/s2k.cpp')
-rw-r--r--src/s2k/s2k.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/s2k/s2k.cpp b/src/s2k/s2k.cpp
index b8a8ef719..42064529d 100644
--- a/src/s2k/s2k.cpp
+++ b/src/s2k/s2k.cpp
@@ -48,7 +48,7 @@ void S2K::change_salt(const MemoryRegion<byte>& new_salt)
void S2K::new_random_salt(RandomNumberGenerator& rng,
u32bit length)
{
- salt.create(length);
+ salt.resize(length);
rng.randomize(salt, length);
}