commit 90767eae542f72b7069a3575bc55944cebc749b6
parent ef42db56c9ad91d10120861a42e70f8e85cc8870
Author: Laurent Bercot <ska-skaware@skarnet.org>
Date: Fri, 27 Mar 2015 16:49:32 +0000
Fixed the sha512 bug. rc for 2.3.3.0.
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/libstdcrypto/sha512_final.c b/src/libstdcrypto/sha512_final.c
@@ -17,7 +17,7 @@ void sha512_final (SHA512Schedule *ctx, char *digest)
sha512_transform(ctx, ctx->buf) ;
pad = 0 ;
}
- byte_zero(ctx + pad, 120 - pad) ;
+ byte_zero(ctx->buf + pad, 120 - pad) ;
uint64_pack_big((char *)ctx->buf + 120, ctx->len << 3) ;
sha512_transform(ctx, ctx->buf) ;