X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=engines%2Fccgost%2Fgosthash.c;h=6365c699982a4eac5dcf9c4f2cdfaf561190ed05;hb=6dd9066e0eee6b386460d9c6add681f0bd0fcc9b;hp=de55e0c3aa9dcf55fc3d7ff3a52bf1a5efe42b16;hpb=744ecaa5b6c024c4dfb9036e5efb65f7fec4f784;p=oweals%2Fopenssl.git diff --git a/engines/ccgost/gosthash.c b/engines/ccgost/gosthash.c index de55e0c3aa..6365c69998 100644 --- a/engines/ccgost/gosthash.c +++ b/engines/ccgost/gosthash.c @@ -228,7 +228,7 @@ int finish_hash(gost_hash_ctx *ctx,byte *hashval) byte buf[32]; byte H[32]; byte S[32]; - long long fin_len=ctx->len; + ghosthash_len fin_len=ctx->len; byte *bptr; memcpy(H,ctx->H,32); memcpy(S,ctx->S,32); @@ -245,7 +245,7 @@ int finish_hash(gost_hash_ctx *ctx,byte *hashval) fin_len<<=3; /* Hash length in BITS!!*/ while(fin_len>0) { - *(bptr++)=fin_len&0xFF; + *(bptr++)=(byte)(fin_len&0xFF); fin_len>>=8; }; hash_step(ctx->cipher_ctx,H,buf);