add casts as in head (required for VC++)

This commit is contained in:
Ulf Möller 2002-02-11 17:44:30 +00:00
parent 76dca45720
commit 8935c03618

View file

@ -178,8 +178,10 @@ int MGF1(unsigned char *mask, long len, unsigned char *seed, long seedlen)
for (i = 0; outlen < len; i++)
{
cnt[0] = (i >> 24) & 255, cnt[1] = (i >> 16) & 255,
cnt[2] = (i >> 8) & 255, cnt[3] = i & 255;
cnt[0] = (unsigned char)((i >> 24) & 255);
cnt[1] = (unsigned char)((i >> 16) & 255);
cnt[2] = (unsigned char)((i >> 8)) & 255;
cnt[3] = (unsigned char)(i & 255);
SHA1_Init(&c);
SHA1_Update(&c, seed, seedlen);
SHA1_Update(&c, cnt, 4);