summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/regress/lib/libcrypto/bn/bn_test.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/regress/lib/libcrypto/bn/bn_test.c b/src/regress/lib/libcrypto/bn/bn_test.c
index 93c719e7ff..57068a10c1 100644
--- a/src/regress/lib/libcrypto/bn/bn_test.c
+++ b/src/regress/lib/libcrypto/bn/bn_test.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: bn_test.c,v 1.6 2023/04/07 22:22:10 tb Exp $ */ 1/* $OpenBSD: bn_test.c,v 1.7 2023/04/07 22:23:31 tb 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 *
@@ -481,7 +481,7 @@ test_div(BIO *bp, BN_CTX *ctx)
481 481
482 if (BN_div(d, c, a, b, ctx)) { 482 if (BN_div(d, c, a, b, ctx)) {
483 fprintf(stderr, "Division by zero succeeded!\n"); 483 fprintf(stderr, "Division by zero succeeded!\n");
484 return (0); 484 goto err;
485 } 485 }
486 486
487 for (i = 0; i < num0 + num1; i++) { 487 for (i = 0; i < num0 + num1; i++) {
@@ -893,13 +893,13 @@ test_mont(BIO *bp, BN_CTX *ctx)
893 CHECK_GOTO(BN_zero(n)); 893 CHECK_GOTO(BN_zero(n));
894 if (BN_MONT_CTX_set(mont, n, ctx)) { 894 if (BN_MONT_CTX_set(mont, n, ctx)) {
895 fprintf(stderr, "BN_MONT_CTX_set succeeded for zero modulus!\n"); 895 fprintf(stderr, "BN_MONT_CTX_set succeeded for zero modulus!\n");
896 return (0); 896 goto err;
897 } 897 }
898 898
899 CHECK_GOTO(BN_set_word(n, 16)); 899 CHECK_GOTO(BN_set_word(n, 16));
900 if (BN_MONT_CTX_set(mont, n, ctx)) { 900 if (BN_MONT_CTX_set(mont, n, ctx)) {
901 fprintf(stderr, "BN_MONT_CTX_set succeeded for even modulus!\n"); 901 fprintf(stderr, "BN_MONT_CTX_set succeeded for even modulus!\n");
902 return (0); 902 goto err;
903 } 903 }
904 904
905 CHECK_GOTO(BN_bntest_rand(a, 100, 0, 0)); 905 CHECK_GOTO(BN_bntest_rand(a, 100, 0, 0));
@@ -1031,7 +1031,7 @@ test_mod_mul(BIO *bp, BN_CTX *ctx)
1031 CHECK_GOTO(BN_zero(c)); 1031 CHECK_GOTO(BN_zero(c));
1032 if (BN_mod_mul(e, a, b, c, ctx)) { 1032 if (BN_mod_mul(e, a, b, c, ctx)) {
1033 fprintf(stderr, "BN_mod_mul with zero modulus succeeded!\n"); 1033 fprintf(stderr, "BN_mod_mul with zero modulus succeeded!\n");
1034 return (0); 1034 goto err;
1035 } 1035 }
1036 1036
1037 for (j = 0; j < 3; j++) { 1037 for (j = 0; j < 3; j++) {