summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/bn
diff options
context:
space:
mode:
authormarkus <>2002-09-05 22:44:52 +0000
committermarkus <>2002-09-05 22:44:52 +0000
commit715a204e4615e4a70a466fcb383a9a57cad5e6b8 (patch)
tree2d2e93c4a34d1f7f04aba73706353332d7700641 /src/lib/libcrypto/bn
parent15b5d84f9da2ce4bfae8580e56e34a859f74ad71 (diff)
downloadopenbsd-715a204e4615e4a70a466fcb383a9a57cad5e6b8.tar.gz
openbsd-715a204e4615e4a70a466fcb383a9a57cad5e6b8.tar.bz2
openbsd-715a204e4615e4a70a466fcb383a9a57cad5e6b8.zip
import openssl-0.9.7-beta3
Diffstat (limited to 'src/lib/libcrypto/bn')
-rw-r--r--src/lib/libcrypto/bn/bn_lib.c6
-rw-r--r--src/lib/libcrypto/bn/bn_mul.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/src/lib/libcrypto/bn/bn_lib.c b/src/lib/libcrypto/bn/bn_lib.c
index a016cb7f53..8abe095af2 100644
--- a/src/lib/libcrypto/bn/bn_lib.c
+++ b/src/lib/libcrypto/bn/bn_lib.c
@@ -397,6 +397,12 @@ BIGNUM *bn_dup_expand(const BIGNUM *b, int words)
397 { 397 {
398 BIGNUM *r = NULL; 398 BIGNUM *r = NULL;
399 399
400 /* This function does not work if
401 * words <= b->dmax && top < words
402 * because BN_dup() does not preserve 'dmax'!
403 * (But bn_dup_expand() is not used anywhere yet.)
404 */
405
400 if (words > b->dmax) 406 if (words > b->dmax)
401 { 407 {
402 BN_ULONG *a = bn_expand_internal(b, words); 408 BN_ULONG *a = bn_expand_internal(b, words);
diff --git a/src/lib/libcrypto/bn/bn_mul.c b/src/lib/libcrypto/bn/bn_mul.c
index fd598b8b3d..b03458d002 100644
--- a/src/lib/libcrypto/bn/bn_mul.c
+++ b/src/lib/libcrypto/bn/bn_mul.c
@@ -66,7 +66,7 @@
66#include "cryptlib.h" 66#include "cryptlib.h"
67#include "bn_lcl.h" 67#include "bn_lcl.h"
68 68
69#if defined(OPENSSL_NO_ASM) || !(defined(__i386) || defined(__i386__))/* Assembler implementation exists only for x86 */ 69#if defined(OPENSSL_NO_ASM) || !(defined(__i386) || defined(__i386__)) || defined(__DJGPP__) /* Assembler implementation exists only for x86 */
70/* Here follows specialised variants of bn_add_words() and 70/* Here follows specialised variants of bn_add_words() and
71 bn_sub_words(). They have the property performing operations on 71 bn_sub_words(). They have the property performing operations on
72 arrays of different sizes. The sizes of those arrays is expressed through 72 arrays of different sizes. The sizes of those arrays is expressed through