[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnunet] branch master updated (54bdbf432 -> 2b33fde2a)
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnunet] branch master updated (54bdbf432 -> 2b33fde2a) |
Date: |
Wed, 25 Jan 2017 22:58:12 +0100 |
This is an automated email from the git hooks/post-receive script.
grothoff pushed a change to branch master
in repository gnunet.
from 54bdbf432 allow connect_cb to be NULL
new 8f5f7f788 update ignore file
new 2b33fde2a do not start download twice
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
src/fs/.gitignore | 31 +++++++++++++++++++++++++++++++
src/fs/fs_api.c | 31 +++++++++++++++++++++----------
src/fs/fs_download.c | 28 ++++++++++++++++++++--------
src/set/.gitignore | 4 ++++
4 files changed, 76 insertions(+), 18 deletions(-)
diff --git a/src/fs/.gitignore b/src/fs/.gitignore
index cdfb27108..7f0b0ddc3 100644
--- a/src/fs/.gitignore
+++ b/src/fs/.gitignore
@@ -9,3 +9,34 @@ gnunet-helper-fs-publish
gnunet-publish
gnunet-search
gnunet-service-fs
+test_fs_directory
+test_fs_download
+test_fs_download_cadet
+test_fs_download_indexed
+test_fs_download_persistence
+test_fs_file_information
+test_fs_getopt
+test_fs_list_indexed
+test_fs_namespace
+test_fs_namespace_list_updateable
+test_fs_publish
+test_fs_publish_persistence
+test_fs_search
+test_fs_search_persistence
+test_fs_search_probes
+test_fs_search_with_and
+test_fs_start_stop
+test_fs_test_lib
+test_fs_unindex
+test_fs_unindex_persistence
+test_fs_uri
+test_gnunet_fs_idx.py
+test_gnunet_fs_psd.py
+test_gnunet_fs_rec.py
+test_gnunet_service_fs_migration
+test_gnunet_service_fs_p2p
+test_gnunet_service_fs_p2p_cadet
+test_plugin_block_fs
+perf_gnunet_service_fs_p2p
+perf_gnunet_service_fs_p2p_index
+perf_gnunet_service_fs_p2p_respect
diff --git a/src/fs/fs_api.c b/src/fs/fs_api.c
index 7e769483b..c1ed9521b 100644
--- a/src/fs/fs_api.c
+++ b/src/fs/fs_api.c
@@ -1647,7 +1647,9 @@ deserialize_publish_file (void *cls,
filename, emsg);
GNUNET_free (emsg);
}
- pc->top = GNUNET_FS_make_top (h, &GNUNET_FS_publish_signal_suspend_, pc);
+ pc->top = GNUNET_FS_make_top (h,
+ &GNUNET_FS_publish_signal_suspend_,
+ pc);
return GNUNET_OK;
cleanup:
GNUNET_free_non_null (pc->nid);
@@ -2278,7 +2280,9 @@ deserialize_unindex_file (void *cls,
GNUNET_break (0);
goto cleanup;
}
- uc->top = GNUNET_FS_make_top (h, &GNUNET_FS_unindex_signal_suspend_, uc);
+ uc->top = GNUNET_FS_make_top (h,
+ &GNUNET_FS_unindex_signal_suspend_,
+ uc);
pi.status = GNUNET_FS_STATUS_UNINDEX_RESUME;
pi.value.unindex.specifics.resume.message = uc->emsg;
GNUNET_FS_unindex_make_status_ (&pi, uc,
@@ -2806,7 +2810,8 @@ deserialize_download (struct GNUNET_FS_Handle *h,
GNUNET_FS_compute_depth (GNUNET_FS_uri_chk_get_file_size (dc->uri));
if (GNUNET_FS_uri_test_loc (dc->uri))
GNUNET_assert (GNUNET_OK ==
- GNUNET_FS_uri_loc_get_peer_identity (dc->uri, &dc->target));
+ GNUNET_FS_uri_loc_get_peer_identity (dc->uri,
+ &dc->target));
if (NULL == dc->emsg)
{
dc->top_request = read_download_request (rh);
@@ -2816,10 +2821,14 @@ deserialize_download (struct GNUNET_FS_Handle *h,
goto cleanup;
}
}
- dn = get_download_sync_filename (dc, dc->serialization, ".dir");
+ dn = get_download_sync_filename (dc,
+ dc->serialization,
+ ".dir");
if (NULL != dn)
{
- if (GNUNET_YES == GNUNET_DISK_directory_test (dn, GNUNET_YES))
+ if (GNUNET_YES ==
+ GNUNET_DISK_directory_test (dn,
+ GNUNET_YES))
GNUNET_DISK_directory_scan (dn,
&deserialize_subdownload,
dc);
@@ -2836,17 +2845,19 @@ deserialize_download (struct GNUNET_FS_Handle *h,
dc->search = search;
search->download = dc;
}
- if ((NULL == parent) && (NULL == search))
+ if ( (NULL == parent) &&
+ (NULL == search) )
{
- dc->top =
- GNUNET_FS_make_top (dc->h,
+ dc->top
+ = GNUNET_FS_make_top (dc->h,
&GNUNET_FS_download_signal_suspend_,
dc);
signal_download_resume (dc);
}
GNUNET_free (uris);
- dc->task = GNUNET_SCHEDULER_add_now (&GNUNET_FS_download_start_task_,
- dc);
+ if (NULL == dc->job_queue)
+ dc->task = GNUNET_SCHEDULER_add_now (&GNUNET_FS_download_start_task_,
+ dc);
return;
cleanup:
GNUNET_free_non_null (uris);
diff --git a/src/fs/fs_download.c b/src/fs/fs_download.c
index 53b836f22..a89a95907 100644
--- a/src/fs/fs_download.c
+++ b/src/fs/fs_download.c
@@ -1380,6 +1380,7 @@ try_reconnect (struct GNUNET_FS_DownloadContext *dc)
"Will try to reconnect in %s\n",
GNUNET_STRINGS_relative_time_to_string (dc->reconnect_backoff,
GNUNET_YES));
+ GNUNET_assert (NULL == dc->job_queue);
dc->task =
GNUNET_SCHEDULER_add_delayed (dc->reconnect_backoff,
&do_reconnect,
@@ -1533,7 +1534,7 @@ reconstruct_cont (void *cls)
struct GNUNET_FS_DownloadContext *dc = cls;
/* clean up state from tree encoder */
- if (dc->task != NULL)
+ if (NULL != dc->task)
{
GNUNET_SCHEDULER_cancel (dc->task);
dc->task = NULL;
@@ -1584,9 +1585,13 @@ get_next_block (void *cls)
* @param block_size size of block (in bytes)
*/
static void
-reconstruct_cb (void *cls, const struct ContentHashKey *chk, uint64_t offset,
- unsigned int depth, enum GNUNET_BLOCK_Type type,
- const void *block, uint16_t block_size)
+reconstruct_cb (void *cls,
+ const struct ContentHashKey *chk,
+ uint64_t offset,
+ unsigned int depth,
+ enum GNUNET_BLOCK_Type type,
+ const void *block,
+ uint16_t block_size)
{
struct GNUNET_FS_DownloadContext *dc = cls;
struct GNUNET_FS_ProgressInfo pi;
@@ -1607,7 +1612,8 @@ reconstruct_cb (void *cls, const struct ContentHashKey
*chk, uint64_t offset,
"Block %u < %u irrelevant for our range\n",
chld,
dr->children[0]->chk_idx);
- dc->task = GNUNET_SCHEDULER_add_now (&get_next_block, dc);
+ dc->task = GNUNET_SCHEDULER_add_now (&get_next_block,
+ dc);
return; /* irrelevant block */
}
if (chld > dr->children[dr->num_children-1]->chk_idx)
@@ -1701,8 +1707,10 @@ reconstruct_cb (void *cls, const struct ContentHashKey
*chk, uint64_t offset,
GNUNET_assert (0);
break;
}
- dc->task = GNUNET_SCHEDULER_add_now (&get_next_block, dc);
- if ((dr == dc->top_request) && (dr->state == BRS_DOWNLOAD_UP))
+ dc->task = GNUNET_SCHEDULER_add_now (&get_next_block,
+ dc);
+ if ( (dr == dc->top_request) &&
+ (dr->state == BRS_DOWNLOAD_UP) )
check_completed (dc);
}
@@ -1882,7 +1890,8 @@ GNUNET_FS_download_start_task_ (void *cls)
&reconstruct_cb,
NULL,
&reconstruct_cont);
- dc->task = GNUNET_SCHEDULER_add_now (&get_next_block, dc);
+ dc->task = GNUNET_SCHEDULER_add_now (&get_next_block,
+ dc);
}
else
{
@@ -2037,6 +2046,7 @@ create_download_context (struct GNUNET_FS_Handle *h,
filename,
(unsigned long long) length,
dc->treedepth);
+ GNUNET_assert (NULL == dc->job_queue);
dc->task = GNUNET_SCHEDULER_add_now (&GNUNET_FS_download_start_task_,
dc);
return dc;
@@ -2199,6 +2209,7 @@ GNUNET_FS_download_start_downloading_ (struct
GNUNET_FS_DownloadContext *dc)
if (NULL != dc->mq)
return; /* already running */
GNUNET_assert (NULL == dc->job_queue);
+ GNUNET_assert (NULL == dc->task);
GNUNET_assert (NULL != dc->active);
dc->job_queue =
GNUNET_FS_queue_ (dc->h,
@@ -2240,6 +2251,7 @@ GNUNET_FS_download_resume (struct
GNUNET_FS_DownloadContext *dc)
pi.status = GNUNET_FS_STATUS_DOWNLOAD_ACTIVE;
GNUNET_FS_download_make_status_ (&pi, dc);
+ GNUNET_assert (NULL == dc->task);
dc->job_queue =
GNUNET_FS_queue_ (dc->h,
&activate_fs_download,
diff --git a/src/set/.gitignore b/src/set/.gitignore
index 10f1da0d6..f1c958639 100644
--- a/src/set/.gitignore
+++ b/src/set/.gitignore
@@ -1,3 +1,7 @@
gnunet-set-profiler
gnunet-service-set
gnunet-set-ibf-profiler
+test_set_api
+test_set_intersection_result_full
+test_set_union_copy
+test_set_union_result_symmetric
--
To stop receiving notification emails like this one, please contact
address@hidden
- [GNUnet-SVN] [gnunet] branch master updated (54bdbf432 -> 2b33fde2a),
gnunet <=