From 8691ff97a198db7c54e792cc8dadb9aa4cc8543d Mon Sep 17 00:00:00 2001 From: Andy Polyakov Date: Wed, 16 Feb 2000 13:24:06 +0000 Subject: [PATCH] Move primes to read-only segment. --- crypto/bn/bn_prime.h | 2 +- crypto/bn/bn_prime.pl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crypto/bn/bn_prime.h b/crypto/bn/bn_prime.h index 8bb168517d..b7cf9a9bfe 100644 --- a/crypto/bn/bn_prime.h +++ b/crypto/bn/bn_prime.h @@ -61,7 +61,7 @@ #else #define NUMPRIMES 54 #endif -static unsigned int primes[NUMPRIMES]= +static const unsigned int primes[NUMPRIMES]= { 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, diff --git a/crypto/bn/bn_prime.pl b/crypto/bn/bn_prime.pl index bfe577643a..9fc3765486 100644 --- a/crypto/bn/bn_prime.pl +++ b/crypto/bn/bn_prime.pl @@ -104,7 +104,7 @@ printf "#define NUMPRIMES %d\n",$num; printf "#else\n"; printf "#define NUMPRIMES %d\n",$eight; printf "#endif\n"; -print "static unsigned int primes[NUMPRIMES]=\n\t{\n\t"; +print "static const unsigned int primes[NUMPRIMES]=\n\t{\n\t"; $init=0; for ($i=0; $i <= $#primes; $i++) { -- 2.25.1