From 75a38c89436cfd7541af75d29a2fa225b9b40cfa Mon Sep 17 00:00:00 2001 From: joshua Date: Wed, 9 Nov 2022 12:13:08 +0000 Subject: [PATCH] Remove unnecessary sizeof ok jsing@ tb@ --- regress/lib/libcrypto/rc2/rc2_test.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/regress/lib/libcrypto/rc2/rc2_test.c b/regress/lib/libcrypto/rc2/rc2_test.c index ab95e587f8a..2e503c5c8d0 100644 --- a/regress/lib/libcrypto/rc2/rc2_test.c +++ b/regress/lib/libcrypto/rc2/rc2_test.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rc2_test.c,v 1.5 2022/09/12 13:11:36 tb Exp $ */ +/* $OpenBSD: rc2_test.c,v 1.6 2022/11/09 12:13:08 joshua Exp $ */ /* * Copyright (c) 2022 Joshua Sing * @@ -724,7 +724,7 @@ rc2_evp_test(size_t test_number, const struct rc2_test *rt, const char *label, } for (i = 0; i < rt->in_len;) { - in_len = arc4random_uniform(sizeof(rt->in_len) / 2); + in_len = arc4random_uniform(rt->in_len / 2); if (in_len > rt->in_len - i) in_len = rt->in_len - i; @@ -804,7 +804,7 @@ rc2_evp_test(size_t test_number, const struct rc2_test *rt, const char *label, } for (i = 0; i < rt->out_len;) { - in_len = arc4random_uniform(sizeof(rt->out_len) / 2); + in_len = arc4random_uniform(rt->out_len / 2); if (in_len > rt->out_len - i) in_len = rt->out_len - i; -- 2.20.1