fixed compilation error of demo/demo.c because of missing macro LTM_PRIME_2MSB_OFF

This commit is contained in:
Steffen Jaeckel 2011-03-23 23:25:15 +01:00
parent 6d20c3c6a9
commit fe40673639

View File

@ -179,8 +179,8 @@ printf("compare no compare!\n"); exit(EXIT_FAILURE); }
fflush(stdout);
err =
mp_prime_random_ex(&a, 8, ix,
(rand() & 1) ? LTM_PRIME_2MSB_OFF :
LTM_PRIME_2MSB_ON, myrng, NULL);
(rand() & 1) ? 0 : LTM_PRIME_2MSB_ON,
myrng, NULL);
if (err != MP_OKAY) {
printf("failed with err code %d\n", err);
return EXIT_FAILURE;
@ -196,9 +196,8 @@ printf("compare no compare!\n"); exit(EXIT_FAILURE); }
fflush(stdout);
err =
mp_prime_random_ex(&a, 8, ix,
((rand() & 1) ? LTM_PRIME_2MSB_OFF :
LTM_PRIME_2MSB_ON) | LTM_PRIME_SAFE, myrng,
NULL);
((rand() & 1) ? 0 : LTM_PRIME_2MSB_ON) | LTM_PRIME_SAFE,
myrng, NULL);
if (err != MP_OKAY) {
printf("failed with err code %d\n", err);
return EXIT_FAILURE;