fix build (hopefully)
This commit is contained in:
parent
9cfb6c3298
commit
a91eb5a0d9
@ -625,7 +625,7 @@ static int test_mp_get_u32(void)
|
||||
DOR(mp_init_multi(&a, &b, NULL));
|
||||
|
||||
for (i = 0; i < 1000; ++i) {
|
||||
t = (unsigned long)rand_long() & 0xFFFFFFFFuL;
|
||||
t = (unsigned long)rand_long() & (unsigned long)UINT32_MAX;
|
||||
mp_set_ul(&a, t);
|
||||
if (t != mp_get_u32(&a)) {
|
||||
printf("\nmp_get_u32() bad result!");
|
||||
@ -637,8 +637,8 @@ static int test_mp_get_u32(void)
|
||||
printf("\nmp_get_u32() bad result!");
|
||||
goto LBL_ERR;
|
||||
}
|
||||
mp_set_ul(&a, 0xFFFFFFFFuL);
|
||||
if (mp_get_u32(&a) != 0xFFFFFFFFuL) {
|
||||
mp_set_ul(&a, (unsigned long)UINT32_MAX);
|
||||
if (mp_get_u32(&a) != UINT32_MAX) {
|
||||
printf("\nmp_get_u32() bad result!");
|
||||
goto LBL_ERR;
|
||||
}
|
||||
|
@ -47,7 +47,7 @@ static unsigned long lfsr = 0xAAAAAAAAuL;
|
||||
static unsigned int lbit(void)
|
||||
{
|
||||
if ((lfsr & 0x80000000uL) != 0uL) {
|
||||
lfsr = ((lfsr << 1) ^ 0x8000001BuL) & 0xFFFFFFFFuL;
|
||||
lfsr = ((lfsr << 1) ^ 0x8000001BuL) & (unsigned long)UINT32_MAX;
|
||||
return 1u;
|
||||
} else {
|
||||
lfsr <<= 1;
|
||||
|
Loading…
Reference in New Issue
Block a user