From 1372520972daf599fbaa1f6f0d61a4a8c736db39 Mon Sep 17 00:00:00 2001 From: bigbear Date: Thu, 8 Feb 2024 03:11:55 +0100 Subject: FIX sha1 crash --- includes/sha1.h | 2 +- modules/benchmark/sha1.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/sha1.h b/includes/sha1.h index 573ff8ac..8b5c0b2f 100644 --- a/includes/sha1.h +++ b/includes/sha1.h @@ -17,7 +17,7 @@ typedef struct { - guint32 state[5]; + guint32 state[20]; guint32 count[2]; guchar buffer[64]; } SHA1_CTX; diff --git a/modules/benchmark/sha1.c b/modules/benchmark/sha1.c index b94ce254..3b213218 100644 --- a/modules/benchmark/sha1.c +++ b/modules/benchmark/sha1.c @@ -47,7 +47,7 @@ A million repetitions of "a" /* Hash a single 512-bit block. This is the core of the algorithm. */ -void SHA1Transform(guint32 state[5], guchar buffer[64]) +void SHA1Transform(guint32 state[20], guchar buffer[64]) { guint32 a, b, c, d, e; typedef union { -- cgit v1.2.3