X-Git-Url: https://git.kernel.dk/?a=blobdiff_plain;f=crc%2Fsha1.c;h=8d64c8ee7b836e9322c8c6b9dde01b718f1416d6;hb=38b253f3b6c6c975aa8a5660ab19fa44a7804297;hp=117fbd9c2938b35a57b691ab05cf5a5acb8bcfad;hpb=65d0a0aa0c4e5ed39b804f5f83d311093af798c5;p=fio.git diff --git a/crc/sha1.c b/crc/sha1.c index 117fbd9c..8d64c8ee 100644 --- a/crc/sha1.c +++ b/crc/sha1.c @@ -55,7 +55,7 @@ void fio_sha1_update(struct fio_sha1_ctx *ctx, const void *data, memcpy(ctx->W, data, len); } -void fio_sha1_final(unsigned char hashout[20], struct fio_sha1_ctx *ctx) +void fio_sha1_final(struct fio_sha1_ctx *ctx) { static const unsigned char pad[64] = { 0x80 }; unsigned int padlen[2]; @@ -69,11 +69,6 @@ void fio_sha1_final(unsigned char hashout[20], struct fio_sha1_ctx *ctx) i = ctx->size & 63; fio_sha1_update(ctx, pad, 1+ (63 & (55 - i))); fio_sha1_update(ctx, padlen, 8); - - /* Output hash - */ - for (i = 0; i < 5; i++) - ((unsigned int *)hashout)[i] = htonl(ctx->H[i]); } #if defined(__i386__) || defined(__x86_64__)