projects
/
silc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Integer type name change.
[silc.git]
/
lib
/
silcmath
/
silcprimegen.c
diff --git
a/lib/silcmath/silcprimegen.c
b/lib/silcmath/silcprimegen.c
index 27ed090d0357e76da2c998183549a293f773f8a0..515f2b400fc8a0dc6d5c724f43e2fd9ddd260a25 100644
(file)
--- a/
lib/silcmath/silcprimegen.c
+++ b/
lib/silcmath/silcprimegen.c
@@
-53,7
+53,7
@@
*/
*/
-static
ui
nt32 primetable[] =
+static
SilcUI
nt32 primetable[] =
{
2, 3, 5, 7, 11, 13, 17, 19,
23, 29, 31, 37, 41, 43, 47, 53,
{
2, 3, 5, 7, 11, 13, 17, 19,
23, 29, 31, 37, 41, 43, 47, 53,
@@
-195,11
+195,11
@@
static uint32 primetable[] =
If argument verbose is TRUE this will display some status information
about the progress of generation. */
If argument verbose is TRUE this will display some status information
about the progress of generation. */
-bool silc_math_gen_prime(SilcMPInt *prime,
ui
nt32 bits, bool verbose)
+bool silc_math_gen_prime(SilcMPInt *prime,
SilcUI
nt32 bits, bool verbose)
{
unsigned char *numbuf = NULL;
{
unsigned char *numbuf = NULL;
-
ui
nt32 i, b, k;
-
ui
nt32 *spmods;
+
SilcUI
nt32 i, b, k;
+
SilcUI
nt32 *spmods;
SilcMPInt r, base, tmp, tmp2, oprime;
silc_mp_init(&r);
SilcMPInt r, base, tmp, tmp2, oprime;
silc_mp_init(&r);
@@
-238,7
+238,7
@@
bool silc_math_gen_prime(SilcMPInt *prime, uint32 bits, bool verbose)
/* Init modulo table with the prime candidate and the primes
in the primetable. */
/* Init modulo table with the prime candidate and the primes
in the primetable. */
- spmods = silc_calloc(1, sizeof(primetable) * sizeof(
ui
nt32));
+ spmods = silc_calloc(1, sizeof(primetable) * sizeof(
SilcUI
nt32));
for (i = 0; primetable[i] != 0; i++) {
silc_mp_mod_ui(&tmp, prime, primetable[i]);
spmods[i] = silc_mp_get_ui(&tmp);
for (i = 0; primetable[i] != 0; i++) {
silc_mp_mod_ui(&tmp, prime, primetable[i]);
spmods[i] = silc_mp_get_ui(&tmp);