[Pkg-gnupg-commit] [gnupg1] 11/30: mpi: Minor fix for mpi_pow.
Daniel Kahn Gillmor
dkg at fifthhorseman.net
Wed Aug 2 06:35:09 UTC 2017
This is an automated email from the git hooks/post-receive script.
dkg pushed a commit to branch master
in repository gnupg1.
commit 554ded4854758bf6ca268432fa087f946932a409
Author: NIIBE Yutaka <gniibe at fsij.org>
Date: Fri Jul 7 15:12:00 2017 +0900
mpi: Minor fix for mpi_pow.
* mpi/mpi-pow.c (mpi_powm): Fix allocation size.
Signed-off-by: NIIBE Yutaka <gniibe at fsij.org>
---
mpi/mpi-pow.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/mpi/mpi-pow.c b/mpi/mpi-pow.c
index acddca9..0078b84 100644
--- a/mpi/mpi-pow.c
+++ b/mpi/mpi-pow.c
@@ -162,7 +162,7 @@ mpi_powm( MPI res, MPI base, MPI exponent, MPI mod)
{
mpi_size_t i;
- mpi_ptr_t xp = xp_marker = mpi_alloc_limb_space( 2 * (msize + 1), msec );
+ mpi_ptr_t xp = xp_marker = mpi_alloc_limb_space( size, msec );
int c;
mpi_limb_t e;
mpi_limb_t carry_limb;
@@ -499,7 +499,7 @@ mpi_powm (MPI res, MPI base, MPI expo, MPI mod)
struct karatsuba_ctx karactx;
mpi_ptr_t tp;
- xp = xp_marker = mpi_alloc_limb_space( 2 * (msize + 1), msec );
+ xp = xp_marker = mpi_alloc_limb_space( size, msec );
memset( &karactx, 0, sizeof karactx );
negative_result = (ep[0] & 1) && bsign;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/gnupg1.git
More information about the Pkg-gnupg-commit
mailing list