diff options
author | Niels Möller <nisse@lysator.liu.se> | 2014-04-16 07:10:06 +0200 |
---|---|---|
committer | Niels Möller <nisse@lysator.liu.se> | 2014-04-16 07:10:06 +0200 |
commit | 14b6bc2ce682f1d6558ed61b31e819513cc24a22 (patch) | |
tree | 4fb75ec4920ab4b5917ce150122d7a4f148231b6 /examples | |
parent | 582f234e00c019e6009bea7ab84cb615041cde94 (diff) | |
download | nettle-14b6bc2ce682f1d6558ed61b31e819513cc24a22.tar.gz |
Stylistic fixes.
Diffstat (limited to 'examples')
-rw-r--r-- | examples/eratosthenes.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/eratosthenes.c b/examples/eratosthenes.c index 3e1bd39f..7a54561d 100644 --- a/examples/eratosthenes.c +++ b/examples/eratosthenes.c @@ -93,7 +93,7 @@ static unsigned long * vector_alloc(unsigned long size) { unsigned long end = (size + BITS_PER_LONG - 1) / BITS_PER_LONG; - unsigned long *vector = malloc (end * sizeof(long)); + unsigned long *vector = malloc (end * sizeof(*vector)); if (!vector) { @@ -110,7 +110,7 @@ vector_init(unsigned long *vector, unsigned long size) unsigned long i; for (i = 0; i < end; i++) - vector[i] = ~0; + vector[i] = ~0UL; } static void |