diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/regress/lib/libc/hash/hash_test.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/regress/lib/libc/hash/hash_test.c b/src/regress/lib/libc/hash/hash_test.c index f9dc641186..c04a0458fe 100644 --- a/src/regress/lib/libc/hash/hash_test.c +++ b/src/regress/lib/libc/hash/hash_test.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: hash_test.c,v 1.2 2025/04/14 18:33:56 tb Exp $ */ | 1 | /* $OpenBSD: hash_test.c,v 1.3 2025/08/02 06:05:13 tb Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 2025 Theo Buehler <tb@openbsd.org> | 4 | * Copyright (c) 2025 Theo Buehler <tb@openbsd.org> |
@@ -757,7 +757,7 @@ struct hash_ctx { | |||
757 | void *ctx; | 757 | void *ctx; |
758 | void (*init)(void *); | 758 | void (*init)(void *); |
759 | void (*update)(void *, const uint8_t *, size_t); | 759 | void (*update)(void *, const uint8_t *, size_t); |
760 | void (*final)(void *, void *final); | 760 | void (*final)(void *, void *); |
761 | }; | 761 | }; |
762 | 762 | ||
763 | static const struct hash_tests { | 763 | static const struct hash_tests { |
@@ -814,7 +814,7 @@ hash_test_case(struct hash_ctx *ctx, const struct hash_test_case *tc, | |||
814 | size_t in_len = tc->in != NULL ? strlen(tc->in) : 0; | 814 | size_t in_len = tc->in != NULL ? strlen(tc->in) : 0; |
815 | 815 | ||
816 | ctx->init(ctx->ctx); | 816 | ctx->init(ctx->ctx); |
817 | ctx->update(ctx->ctx, (uint8_t *)tc->in, in_len); | 817 | ctx->update(ctx->ctx, (const uint8_t *)tc->in, in_len); |
818 | ctx->final(ctx->digest, ctx->ctx); | 818 | ctx->final(ctx->digest, ctx->ctx); |
819 | 819 | ||
820 | if (memcmp(tc->out, ctx->digest, ctx->digest_len) != 0) { | 820 | if (memcmp(tc->out, ctx->digest, ctx->digest_len) != 0) { |