summaryrefslogtreecommitdiff
path: root/src/set/strata_estimator.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/set/strata_estimator.c')
-rw-r--r--src/set/strata_estimator.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/set/strata_estimator.c b/src/set/strata_estimator.c
index c719a5836..a148c1488 100644
--- a/src/set/strata_estimator.c
+++ b/src/set/strata_estimator.c
@@ -89,7 +89,7 @@ strata_estimator_create (unsigned int strata_count, uint32_t ibf_size, uint8_t i
/* fixme: allocate everything in one chunk */
- se = GNUNET_malloc (sizeof (struct StrataEstimator));
+ se = GNUNET_new (struct StrataEstimator);
se->strata_count = strata_count;
se->ibf_size = ibf_size;
se->strata = GNUNET_malloc (sizeof (struct InvertibleBloomFilter *) * strata_count);
@@ -159,7 +159,7 @@ strata_estimator_dup (struct StrataEstimator *se)
struct StrataEstimator *c;
int i;
- c = GNUNET_malloc (sizeof (struct StrataEstimator));
+ c = GNUNET_new (struct StrataEstimator);
c->strata_count = se->strata_count;
c->ibf_size = se->ibf_size;
c->strata = GNUNET_malloc (sizeof (struct InvertibleBloomFilter *) * se->strata_count);