aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDario Niedermann <[email protected]>2017-11-10 14:45:59 +0000
committerWerner Koch <[email protected]>2017-11-10 14:45:59 +0000
commit877e3073d731fec55a88673f91ed646a75e786c8 (patch)
treef98211276d730e0e595301aaea59c897f6a230ba
parentbuild: Don't use /dev/srandom on OpenBSD (diff)
downloadgnupg-877e3073d731fec55a88673f91ed646a75e786c8.tar.gz
gnupg-877e3073d731fec55a88673f91ed646a75e786c8.zip
Do not use C99 feature.
* cipher/rsa.c (secret): Move var decl to the beginning. -- Trivial patch; ChangeLog written by wk. Signed-off-by: Werner Koch <[email protected]>
-rw-r--r--cipher/rsa.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/cipher/rsa.c b/cipher/rsa.c
index 51b76404f..b3ecd3bea 100644
--- a/cipher/rsa.c
+++ b/cipher/rsa.c
@@ -304,6 +304,9 @@ secret(MPI output, MPI input, RSA_secret_key *skey )
#if 0
mpi_powm( output, input, skey->d, skey->n );
#else
+ MPI D_blind;
+ MPI rr;
+ unsigned int rr_nbits;
int nlimbs = mpi_get_nlimbs (skey->n)+1;
MPI m1 = mpi_alloc_secure (nlimbs);
MPI m2 = mpi_alloc_secure (nlimbs);
@@ -326,9 +329,7 @@ secret(MPI output, MPI input, RSA_secret_key *skey )
# endif /* USE_BLINDING */
/* RSA secret operation: */
- MPI D_blind = mpi_alloc_secure (nlimbs);
- MPI rr;
- unsigned int rr_nbits;
+ D_blind = mpi_alloc_secure (nlimbs);
rr_nbits = mpi_get_nbits (skey->p) / 4;
if (rr_nbits < 96)