mirror of
git://git.sv.gnu.org/coreutils.git
synced 2026-04-20 10:51:48 +02:00
sha512_process_bytes: fix a bug in processing a buffer where length&64 != 0
* gl/lib/sha512.c (sha512_process_bytes): s/63/127/.
This commit is contained in:
committed by
Jim Meyering
parent
a5d8b18bea
commit
c960211fe7
@@ -345,7 +345,7 @@ sha512_process_bytes (const void *buffer, size_t len, struct sha512_ctx *ctx)
|
||||
|
||||
if (ctx->buflen > 128)
|
||||
{
|
||||
sha512_process_block (ctx->buffer, ctx->buflen & ~63, ctx);
|
||||
sha512_process_block (ctx->buffer, ctx->buflen & ~127, ctx);
|
||||
|
||||
ctx->buflen &= 127;
|
||||
/* The regions in the following copy operation cannot overlap. */
|
||||
|
||||
Reference in New Issue
Block a user