summaryrefslogtreecommitdiffstats
path: root/crypto/bn/bn_lib.c
diff options
context:
space:
mode:
authorNils Larsch <nils@openssl.org>2005-05-03 20:27:00 +0000
committerNils Larsch <nils@openssl.org>2005-05-03 20:27:00 +0000
commitf15c448a7261fb1edc983387c59e1d09f20f91a0 (patch)
treea4491298bd4e85db8906c420141473bad4dcb6da /crypto/bn/bn_lib.c
parentfcb41c0ee8632a323bd2c2e39f401c4fcf31f3d4 (diff)
remove BN_ncopy, it was only used in bn_nist.c and wasn't particular
useful anyway
Diffstat (limited to 'crypto/bn/bn_lib.c')
-rw-r--r--crypto/bn/bn_lib.c40
1 files changed, 0 insertions, 40 deletions
diff --git a/crypto/bn/bn_lib.c b/crypto/bn/bn_lib.c
index 05d35982e5..3c4d5459f6 100644
--- a/crypto/bn/bn_lib.c
+++ b/crypto/bn/bn_lib.c
@@ -531,46 +531,6 @@ BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
return(a);
}
-BIGNUM *BN_ncopy(BIGNUM *a, const BIGNUM *b, size_t n)
- {
- int i, min;
- BN_ULONG *A;
- const BN_ULONG *B;
-
- bn_check_top(b);
- if (a == b)
- return a;
-
- min = (b->top < (int)n)? b->top: (int)n;
- if (!min)
- {
- BN_zero(a);
- return a;
- }
- if (bn_wexpand(a, min) == NULL)
- return NULL;
-
- A=a->d;
- B=b->d;
- for (i=min>>2; i>0; i--, A+=4, B+=4)
- {
- BN_ULONG a0,a1,a2,a3;
- a0=B[0]; a1=B[1]; a2=B[2]; a3=B[3];
- A[0]=a0; A[1]=a1; A[2]=a2; A[3]=a3;
- }
- switch (min&3)
- {
- case 3: A[2]=B[2];
- case 2: A[1]=B[1];
- case 1: A[0]=B[0];
- case 0: ;
- }
- a->top = min;
- a->neg = b->neg;
- bn_correct_top(a);
- return(a);
- }
-
void BN_swap(BIGNUM *a, BIGNUM *b)
{
int flags_old_a, flags_old_b;