forked from Telodendria/Telodendria
Fix overflow on some platforms
This commit is contained in:
parent
b8027e1aaf
commit
72bfa34bcd
1 changed files with 2 additions and 2 deletions
|
@ -187,7 +187,7 @@ Sha256(char *str)
|
|||
unsigned char out[32];
|
||||
char *outStr;
|
||||
|
||||
char fill[64];
|
||||
unsigned char fill[64];
|
||||
uint32_t fillLen;
|
||||
unsigned char buf[8];
|
||||
uint32_t hiLen;
|
||||
|
@ -229,7 +229,7 @@ Sha256(char *str)
|
|||
PUT_UINT32(&buf[0], hiLen);
|
||||
PUT_UINT32(&buf[4], loLen);
|
||||
|
||||
Sha256Process(&context, (unsigned char *) fill, fillLen);
|
||||
Sha256Process(&context, fill, fillLen);
|
||||
Sha256Process(&context, buf, 8);
|
||||
|
||||
for (i = 0; i < 8; i++)
|
||||
|
|
Loading…
Reference in a new issue