aboutsummaryrefslogtreecommitdiff
path: root/src/fs/fs_tree.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-09-15 18:23:27 +0000
committerChristian Grothoff <christian@grothoff.org>2013-09-15 18:23:27 +0000
commit8b20ea06fdb75740cead194d5c6826b4233ec500 (patch)
treeb96b67ef0785a2bf9f1db49cee82e8cc5da4843e /src/fs/fs_tree.c
parent34f5392dc97d411d437c963af3a6a8ade2529306 (diff)
downloadgnunet-8b20ea06fdb75740cead194d5c6826b4233ec500.tar.gz
gnunet-8b20ea06fdb75740cead194d5c6826b4233ec500.zip
-doxygen fixes, and fixing publish URI serization for proper resume
Diffstat (limited to 'src/fs/fs_tree.c')
-rw-r--r--src/fs/fs_tree.c26
1 files changed, 19 insertions, 7 deletions
diff --git a/src/fs/fs_tree.c b/src/fs/fs_tree.c
index 762989824..b9dd894f5 100644
--- a/src/fs/fs_tree.c
+++ b/src/fs/fs_tree.c
@@ -416,19 +416,33 @@ GNUNET_FS_tree_encoder_next (struct GNUNET_FS_TreeEncoder *te)
416 416
417 417
418/** 418/**
419 * Get the resulting URI from the encoding.
420 *
421 * @param te the tree encoder to clean up
422 * @return uri set to the resulting URI (if encoding finished), NULL otherwise
423 */
424struct GNUNET_FS_Uri *
425GNUNET_FS_tree_encoder_get_uri (struct GNUNET_FS_TreeEncoder *te)
426{
427 if (NULL != te->uri)
428 return GNUNET_FS_uri_dup (te->uri);
429 return NULL;
430}
431
432
433/**
419 * Clean up a tree encoder and return information 434 * Clean up a tree encoder and return information
420 * about the resulting URI or an error message. 435 * about possible errors.
421 * 436 *
422 * @param te the tree encoder to clean up 437 * @param te the tree encoder to clean up
423 * @param uri set to the resulting URI (if encoding finished)
424 * @param emsg set to an error message (if an error occured 438 * @param emsg set to an error message (if an error occured
425 * within the tree encoder; if this function is called 439 * within the tree encoder; if this function is called
426 * prior to completion and prior to an internal error, 440 * prior to completion and prior to an internal error,
427 * both "*uri" and "*emsg" will be set to NULL). 441 * both "*emsg" will be set to NULL).
428 */ 442 */
429void 443void
430GNUNET_FS_tree_encoder_finish (struct GNUNET_FS_TreeEncoder *te, 444GNUNET_FS_tree_encoder_finish (struct GNUNET_FS_TreeEncoder *te,
431 struct GNUNET_FS_Uri **uri, char **emsg) 445 char **emsg)
432{ 446{
433 if (NULL != te->reader) 447 if (NULL != te->reader)
434 { 448 {
@@ -436,9 +450,7 @@ GNUNET_FS_tree_encoder_finish (struct GNUNET_FS_TreeEncoder *te,
436 te->reader = NULL; 450 te->reader = NULL;
437 } 451 }
438 GNUNET_assert (GNUNET_NO == te->in_next); 452 GNUNET_assert (GNUNET_NO == te->in_next);
439 if (uri != NULL) 453 if (NULL != te->uri)
440 *uri = te->uri;
441 else if (NULL != te->uri)
442 GNUNET_FS_uri_destroy (te->uri); 454 GNUNET_FS_uri_destroy (te->uri);
443 if (emsg != NULL) 455 if (emsg != NULL)
444 *emsg = te->emsg; 456 *emsg = te->emsg;