aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/math/bigint
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/math/bigint')
-rw-r--r--src/lib/math/bigint/bigint.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/lib/math/bigint/bigint.cpp b/src/lib/math/bigint/bigint.cpp
index 50e93c38d..c822a94e1 100644
--- a/src/lib/math/bigint/bigint.cpp
+++ b/src/lib/math/bigint/bigint.cpp
@@ -260,6 +260,8 @@ void BigInt::reduce_below(const BigInt& p, secure_vector<word>& ws)
if(ws.size() < p_words + 1)
ws.resize(p_words + 1);
+ clear_mem(ws.data(), ws.size());
+
for(;;)
{
word borrow = bigint_sub3(ws.data(), data(), p_words + 1, p.data(), p_words);