X-Git-Url: https://git.distorted.org.uk/~mdw/secnet/blobdiff_plain/389070fed67552c613ce5afd3cdb436f8f8c538f..b85fe3f90b025a3742bf1c0ea91bc213a421f74d:/md5.c diff --git a/md5.c b/md5.c index 0ce1200..343ad8f 100644 --- a/md5.c +++ b/md5.c @@ -26,7 +26,7 @@ #ifdef WORDS_BIGENDIAN static void -byteSwap(uint32_t *buf, unsigned words) +byteSwap(uint32_t *buf, int words) { md5byte *p = (md5byte *)buf; @@ -129,7 +129,7 @@ MD5Final(md5byte digest[16], struct MD5Context *ctx) byteSwap(ctx->buf, 4); memcpy(digest, ctx->buf, 16); - memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */ + memset(ctx, 0, sizeof *ctx); /* In case it's sensitive */ } #ifndef ASM_MD5 @@ -247,7 +247,7 @@ static void *md5_init(void) return ctx; } -static void md5_update(void *sst, uint8_t const *buf, uint32_t len) +static void md5_update(void *sst, const void *buf, int32_t len) { struct MD5Context *ctx=sst;