diff options
Diffstat (limited to 'src/util/container_bloomfilter.c')
-rw-r--r-- | src/util/container_bloomfilter.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/util/container_bloomfilter.c b/src/util/container_bloomfilter.c index 8c226f67d..8d0852fc9 100644 --- a/src/util/container_bloomfilter.c +++ b/src/util/container_bloomfilter.c | |||
@@ -340,9 +340,9 @@ typedef int (*BitIterator) (void *cls, | |||
340 | */ | 340 | */ |
341 | static void | 341 | static void |
342 | iterateBits (const struct GNUNET_CONTAINER_BloomFilter *bf, | 342 | iterateBits (const struct GNUNET_CONTAINER_BloomFilter *bf, |
343 | BitIterator callback, void *arg, const GNUNET_HashCode * key) | 343 | BitIterator callback, void *arg, const struct GNUNET_HashCode * key) |
344 | { | 344 | { |
345 | GNUNET_HashCode tmp[2]; | 345 | struct GNUNET_HashCode tmp[2]; |
346 | int bitCount; | 346 | int bitCount; |
347 | unsigned int round; | 347 | unsigned int round; |
348 | unsigned int slot = 0; | 348 | unsigned int slot = 0; |
@@ -354,7 +354,7 @@ iterateBits (const struct GNUNET_CONTAINER_BloomFilter *bf, | |||
354 | GNUNET_assert (bf->bitArraySize * 8LL > bf->bitArraySize); | 354 | GNUNET_assert (bf->bitArraySize * 8LL > bf->bitArraySize); |
355 | while (bitCount > 0) | 355 | while (bitCount > 0) |
356 | { | 356 | { |
357 | while (slot < (sizeof (GNUNET_HashCode) / sizeof (uint32_t))) | 357 | while (slot < (sizeof (struct GNUNET_HashCode) / sizeof (uint32_t))) |
358 | { | 358 | { |
359 | if (GNUNET_YES != | 359 | if (GNUNET_YES != |
360 | callback (arg, bf, | 360 | callback (arg, bf, |
@@ -368,7 +368,7 @@ iterateBits (const struct GNUNET_CONTAINER_BloomFilter *bf, | |||
368 | } | 368 | } |
369 | if (bitCount > 0) | 369 | if (bitCount > 0) |
370 | { | 370 | { |
371 | GNUNET_CRYPTO_hash (&tmp[round & 1], sizeof (GNUNET_HashCode), | 371 | GNUNET_CRYPTO_hash (&tmp[round & 1], sizeof (struct GNUNET_HashCode), |
372 | &tmp[(round + 1) & 1]); | 372 | &tmp[(round + 1) & 1]); |
373 | round++; | 373 | round++; |
374 | slot = 0; | 374 | slot = 0; |
@@ -696,7 +696,7 @@ GNUNET_CONTAINER_bloomfilter_clear (struct GNUNET_CONTAINER_BloomFilter *bf) | |||
696 | */ | 696 | */ |
697 | int | 697 | int |
698 | GNUNET_CONTAINER_bloomfilter_test (const struct GNUNET_CONTAINER_BloomFilter | 698 | GNUNET_CONTAINER_bloomfilter_test (const struct GNUNET_CONTAINER_BloomFilter |
699 | *bf, const GNUNET_HashCode * e) | 699 | *bf, const struct GNUNET_HashCode * e) |
700 | { | 700 | { |
701 | int res; | 701 | int res; |
702 | 702 | ||
@@ -716,7 +716,7 @@ GNUNET_CONTAINER_bloomfilter_test (const struct GNUNET_CONTAINER_BloomFilter | |||
716 | */ | 716 | */ |
717 | void | 717 | void |
718 | GNUNET_CONTAINER_bloomfilter_add (struct GNUNET_CONTAINER_BloomFilter *bf, | 718 | GNUNET_CONTAINER_bloomfilter_add (struct GNUNET_CONTAINER_BloomFilter *bf, |
719 | const GNUNET_HashCode * e) | 719 | const struct GNUNET_HashCode * e) |
720 | { | 720 | { |
721 | if (NULL == bf) | 721 | if (NULL == bf) |
722 | return; | 722 | return; |
@@ -801,7 +801,7 @@ GNUNET_CONTAINER_bloomfilter_or2 (struct GNUNET_CONTAINER_BloomFilter *bf, | |||
801 | */ | 801 | */ |
802 | void | 802 | void |
803 | GNUNET_CONTAINER_bloomfilter_remove (struct GNUNET_CONTAINER_BloomFilter *bf, | 803 | GNUNET_CONTAINER_bloomfilter_remove (struct GNUNET_CONTAINER_BloomFilter *bf, |
804 | const GNUNET_HashCode * e) | 804 | const struct GNUNET_HashCode * e) |
805 | { | 805 | { |
806 | if (NULL == bf) | 806 | if (NULL == bf) |
807 | return; | 807 | return; |
@@ -827,7 +827,7 @@ GNUNET_CONTAINER_bloomfilter_resize (struct GNUNET_CONTAINER_BloomFilter *bf, | |||
827 | void *iterator_cls, size_t size, | 827 | void *iterator_cls, size_t size, |
828 | unsigned int k) | 828 | unsigned int k) |
829 | { | 829 | { |
830 | GNUNET_HashCode hc; | 830 | struct GNUNET_HashCode hc; |
831 | unsigned int i; | 831 | unsigned int i; |
832 | 832 | ||
833 | GNUNET_free (bf->bitArray); | 833 | GNUNET_free (bf->bitArray); |