summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/bn/bn_prime.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/bn/bn_prime.c')
-rw-r--r--src/lib/libcrypto/bn/bn_prime.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/lib/libcrypto/bn/bn_prime.c b/src/lib/libcrypto/bn/bn_prime.c
index bf3f931644..0ba288c46a 100644
--- a/src/lib/libcrypto/bn/bn_prime.c
+++ b/src/lib/libcrypto/bn/bn_prime.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: bn_prime.c,v 1.26 2022/11/09 22:52:51 tb Exp $ */ 1/* $OpenBSD: bn_prime.c,v 1.27 2022/11/26 13:56:33 jsing Exp $ */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
@@ -232,7 +232,6 @@ BN_generate_prime_ex(BIGNUM *ret, int bits, int safe, const BIGNUM *add,
232 err: 232 err:
233 BN_CTX_end(ctx); 233 BN_CTX_end(ctx);
234 BN_CTX_free(ctx); 234 BN_CTX_free(ctx);
235 bn_check_top(ret);
236 235
237 return found; 236 return found;
238} 237}
@@ -288,7 +287,6 @@ loop:
288 } 287 }
289 if (!BN_add_word(rnd, delta)) 288 if (!BN_add_word(rnd, delta))
290 return (0); 289 return (0);
291 bn_check_top(rnd);
292 return (1); 290 return (1);
293} 291}
294 292
@@ -338,7 +336,6 @@ loop:
338 336
339err: 337err:
340 BN_CTX_end(ctx); 338 BN_CTX_end(ctx);
341 bn_check_top(rnd);
342 return (ret); 339 return (ret);
343} 340}
344 341
@@ -406,6 +403,5 @@ loop:
406 403
407err: 404err:
408 BN_CTX_end(ctx); 405 BN_CTX_end(ctx);
409 bn_check_top(p);
410 return (ret); 406 return (ret);
411} 407}