diff options
author | LRN <lrn1986@gmail.com> | 2013-12-19 06:00:23 +0000 |
---|---|---|
committer | LRN <lrn1986@gmail.com> | 2013-12-19 06:00:23 +0000 |
commit | e0ca7357cd0bfedc5c29cb731b56279fef8da059 (patch) | |
tree | ecfd47cf59bc00e656b53fd59c58f5038e342d65 /src/fs/fs_tree.c | |
parent | 92fd84dc7ef98452f848a62677c61a2b80b5835e (diff) | |
download | gnunet-e0ca7357cd0bfedc5c29cb731b56279fef8da059.tar.gz gnunet-e0ca7357cd0bfedc5c29cb731b56279fef8da059.zip |
malloc -> new
Diffstat (limited to 'src/fs/fs_tree.c')
-rw-r--r-- | src/fs/fs_tree.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fs/fs_tree.c b/src/fs/fs_tree.c index 4e0ef8c5b..5dc39e4e6 100644 --- a/src/fs/fs_tree.c +++ b/src/fs/fs_tree.c | |||
@@ -276,7 +276,7 @@ GNUNET_FS_tree_encoder_create (struct GNUNET_FS_Handle *h, uint64_t size, | |||
276 | { | 276 | { |
277 | struct GNUNET_FS_TreeEncoder *te; | 277 | struct GNUNET_FS_TreeEncoder *te; |
278 | 278 | ||
279 | te = GNUNET_malloc (sizeof (struct GNUNET_FS_TreeEncoder)); | 279 | te = GNUNET_new (struct GNUNET_FS_TreeEncoder); |
280 | te->h = h; | 280 | te->h = h; |
281 | te->size = size; | 281 | te->size = size; |
282 | te->cls = cls; | 282 | te->cls = cls; |
@@ -347,7 +347,7 @@ GNUNET_FS_tree_encoder_next (struct GNUNET_FS_TreeEncoder *te) | |||
347 | off = CHK_PER_INODE * (te->chk_tree_depth - 1); | 347 | off = CHK_PER_INODE * (te->chk_tree_depth - 1); |
348 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "TE done, reading CHK `%s' from %u\n", | 348 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "TE done, reading CHK `%s' from %u\n", |
349 | GNUNET_h2s (&te->chk_tree[off].query), off); | 349 | GNUNET_h2s (&te->chk_tree[off].query), off); |
350 | te->uri = GNUNET_malloc (sizeof (struct GNUNET_FS_Uri)); | 350 | te->uri = GNUNET_new (struct GNUNET_FS_Uri); |
351 | te->uri->type = GNUNET_FS_URI_CHK; | 351 | te->uri->type = GNUNET_FS_URI_CHK; |
352 | te->uri->data.chk.chk = te->chk_tree[off]; | 352 | te->uri->data.chk.chk = te->chk_tree[off]; |
353 | te->uri->data.chk.file_length = GNUNET_htonll (te->size); | 353 | te->uri->data.chk.file_length = GNUNET_htonll (te->size); |