mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-08 12:44:23 +01:00
* longlong.h: Typo.
* mpi-pow.c (mpi_powm): s/exp/exponent/ to shutup a compiler warning. From Werner on stable branch.
This commit is contained in:
parent
2815f9fa49
commit
c19c728afa
@ -1,3 +1,10 @@
|
||||
2004-05-20 David Shaw <dshaw@jabberwocky.com>
|
||||
|
||||
* longlong.h: Typo.
|
||||
|
||||
* mpi-pow.c (mpi_powm): s/exp/exponent/ to shutup a compiler
|
||||
warning. From Werner on stable branch.
|
||||
|
||||
2004-01-20 David Shaw <dshaw@jabberwocky.com>
|
||||
|
||||
* hppa1.1/udiv-qrnnd.S: Alignment fix from Lamont Jones for
|
||||
|
@ -924,7 +924,7 @@ extern USItype __udiv_qrnnd ();
|
||||
/* Powerpc 64 bit support taken from gmp-4.1.2. */
|
||||
/* We should test _IBMR2 here when we add assembly support for the system
|
||||
vendor compilers. */
|
||||
#if 0 /* Not yet enabled becuase we don't have hardware for a test. */
|
||||
#if 0 /* Not yet enabled because we don't have hardware for a test. */
|
||||
#if (defined (_ARCH_PPC) || defined (__powerpc__)) && W_TYPE_SIZE == 64
|
||||
#define add_ssaaaa(sh, sl, ah, al, bh, bl) \
|
||||
do { \
|
||||
|
@ -39,7 +39,7 @@
|
||||
* RES = BASE ^ EXP mod MOD
|
||||
*/
|
||||
void
|
||||
mpi_powm( MPI res, MPI base, MPI exp, MPI mod)
|
||||
mpi_powm( MPI res, MPI base, MPI exponent, MPI mod)
|
||||
{
|
||||
mpi_ptr_t rp, ep, mp, bp;
|
||||
mpi_size_t esize, msize, bsize, rsize;
|
||||
@ -55,19 +55,19 @@ mpi_powm( MPI res, MPI base, MPI exp, MPI mod)
|
||||
mpi_size_t tsize=0; /* to avoid compiler warning */
|
||||
/* fixme: we should check that the warning is void*/
|
||||
|
||||
esize = exp->nlimbs;
|
||||
esize = exponent->nlimbs;
|
||||
msize = mod->nlimbs;
|
||||
size = 2 * msize;
|
||||
esign = exp->sign;
|
||||
esign = exponent->sign;
|
||||
msign = mod->sign;
|
||||
|
||||
esec = mpi_is_secure(exp);
|
||||
esec = mpi_is_secure(exponent);
|
||||
msec = mpi_is_secure(mod);
|
||||
bsec = mpi_is_secure(base);
|
||||
rsec = mpi_is_secure(res);
|
||||
|
||||
rp = res->d;
|
||||
ep = exp->d;
|
||||
ep = exponent->d;
|
||||
|
||||
if( !msize )
|
||||
msize = 1 / msize; /* provoke a signal */
|
||||
@ -129,7 +129,7 @@ mpi_powm( MPI res, MPI base, MPI exp, MPI mod)
|
||||
rp = res->d;
|
||||
}
|
||||
}
|
||||
else { /* Make BASE, EXP and MOD not overlap with RES. */
|
||||
else { /* Make BASE, EXPONENT and MOD not overlap with RES. */
|
||||
if( rp == bp ) {
|
||||
/* RES and BASE are identical. Allocate temp. space for BASE. */
|
||||
assert( !bp_marker );
|
||||
@ -137,7 +137,8 @@ mpi_powm( MPI res, MPI base, MPI exp, MPI mod)
|
||||
MPN_COPY(bp, rp, bsize);
|
||||
}
|
||||
if( rp == ep ) {
|
||||
/* RES and EXP are identical. Allocate temp. space for EXP. */
|
||||
/* RES and EXPONENT are identical.
|
||||
Allocate temp. space for EXPONENT. */
|
||||
ep = ep_marker = mpi_alloc_limb_space( esize, esec );
|
||||
MPN_COPY(ep, rp, esize);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user