diff options
author | Jack Lloyd <[email protected]> | 2018-09-30 16:45:20 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2018-09-30 16:45:20 -0400 |
commit | 38f053a5f8cb1ca351ba52d76c15491d63fd3eb0 (patch) | |
tree | 13c06b095059af302b8e0d9562a4aa7a9a6e73b1 /src/lib/pubkey | |
parent | e9ba0d9cdf0726b357d7aeca14ef43f1d10be1e8 (diff) |
Fix some MSVC warnings
Diffstat (limited to 'src/lib/pubkey')
-rw-r--r-- | src/lib/pubkey/ec_group/point_mul.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/pubkey/ec_group/point_mul.cpp b/src/lib/pubkey/ec_group/point_mul.cpp index 760f060ce..da3abaacc 100644 --- a/src/lib/pubkey/ec_group/point_mul.cpp +++ b/src/lib/pubkey/ec_group/point_mul.cpp @@ -170,7 +170,7 @@ PointGFp_Var_Point_Precompute::PointGFp_Var_Point_Precompute(const PointGFp& poi if(ws.size() < PointGFp::WORKSPACE_SIZE) ws.resize(PointGFp::WORKSPACE_SIZE); - std::vector<PointGFp> U(1U << m_window_bits); + std::vector<PointGFp> U(static_cast<size_t>(1) << m_window_bits); U[0] = point.zero(); U[1] = point; @@ -354,10 +354,10 @@ PointGFp PointGFp_Multi_Point_Precompute::multi_exp(const BigInt& z1, H.mult2i(2, ws); } - const uint8_t z1_b = z1.get_substring(z_bits - i - 2, 2); - const uint8_t z2_b = z2.get_substring(z_bits - i - 2, 2); + const uint32_t z1_b = z1.get_substring(z_bits - i - 2, 2); + const uint32_t z2_b = z2.get_substring(z_bits - i - 2, 2); - const uint8_t z12 = (4*z2_b) + z1_b; + const uint32_t z12 = (4*z2_b) + z1_b; // This function is not intended to be const time if(z12) |