diff options
author | Jack Lloyd <[email protected]> | 2019-07-10 10:34:38 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2019-07-10 10:34:38 -0400 |
commit | 73d3b0cbe5b4963f225dc8df2f9948e2c186a113 (patch) | |
tree | 58dce2b8b5ebed8a803972565850899c8abb2686 /src/lib | |
parent | a049eaef7a375833767fece551740b338c52d224 (diff) |
Fix Coverity issue
I think this is a false positive but whatever
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/math/numbertheory/monty_exp.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/lib/math/numbertheory/monty_exp.cpp b/src/lib/math/numbertheory/monty_exp.cpp index f067f33f8..02ae795cd 100644 --- a/src/lib/math/numbertheory/monty_exp.cpp +++ b/src/lib/math/numbertheory/monty_exp.cpp @@ -54,11 +54,9 @@ Montgomery_Exponentation_State::Montgomery_Exponentation_State(std::shared_ptr<c m_g.push_back(Montgomery_Int(m_params, g)); - const Montgomery_Int& monty_g = m_g[1]; - for(size_t i = 2; i != window_size; ++i) { - m_g.push_back(monty_g * m_g[i - 1]); + m_g.push_back(m_g[1] * m_g[i - 1]); } // Resize each element to exactly p words |