aboutsummaryrefslogtreecommitdiff
path: root/src/statistics/statistics_api.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-04-24 13:11:46 +0000
committerChristian Grothoff <christian@grothoff.org>2012-04-24 13:11:46 +0000
commit054520ef90f692998c1bba369abd78eb5d7b6a8b (patch)
treeb47971f4d67e59a2dcb155d22079d91fc665c3e6 /src/statistics/statistics_api.c
parentd8d59fb0a0fbaf640ae1c5fd0ad750dd3b8be1fc (diff)
downloadgnunet-054520ef90f692998c1bba369abd78eb5d7b6a8b.tar.gz
gnunet-054520ef90f692998c1bba369abd78eb5d7b6a8b.zip
-cleaner warning
Diffstat (limited to 'src/statistics/statistics_api.c')
-rw-r--r--src/statistics/statistics_api.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/statistics/statistics_api.c b/src/statistics/statistics_api.c
index 44e763821..8b61a3bc9 100644
--- a/src/statistics/statistics_api.c
+++ b/src/statistics/statistics_api.c
@@ -436,6 +436,9 @@ do_destroy (void *cls,
436static void 436static void
437reconnect_later (struct GNUNET_STATISTICS_Handle *h) 437reconnect_later (struct GNUNET_STATISTICS_Handle *h)
438{ 438{
439 int loss;
440 struct GNUNET_STATISTICS_GetHandle *gh;
441
439 GNUNET_assert (GNUNET_SCHEDULER_NO_TASK == h->backoff_task); 442 GNUNET_assert (GNUNET_SCHEDULER_NO_TASK == h->backoff_task);
440 if (h->do_destroy) 443 if (h->do_destroy)
441 { 444 {
@@ -444,7 +447,13 @@ reconnect_later (struct GNUNET_STATISTICS_Handle *h)
444 * it anymore. 447 * it anymore.
445 * Give up and don't sync the rest of the data. 448 * Give up and don't sync the rest of the data.
446 */ 449 */
447 GNUNET_break (0); 450 loss = GNUNET_NO;
451 for (gh = h->action_head; NULL != gh; gh = gh->next)
452 if ( (gh->make_persistent) && (gh->type == ACTION_SET) )
453 loss = GNUNET_YES;
454 if (GNUNET_YES == loss)
455 GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
456 _("Could not save some persistent statistics\n"));
448 h->do_destroy = GNUNET_NO; 457 h->do_destroy = GNUNET_NO;
449 GNUNET_SCHEDULER_add_continuation (&do_destroy, h, 458 GNUNET_SCHEDULER_add_continuation (&do_destroy, h,
450 GNUNET_SCHEDULER_REASON_PREREQ_DONE); 459 GNUNET_SCHEDULER_REASON_PREREQ_DONE);
@@ -907,7 +916,7 @@ GNUNET_STATISTICS_destroy (struct GNUNET_STATISTICS_Handle *h, int sync_first)
907 h->action_tail, 916 h->action_tail,
908 h->current); 917 h->current);
909 h->do_destroy = GNUNET_YES; 918 h->do_destroy = GNUNET_YES;
910 if ((h->current != NULL) && (h->th == NULL)&& 919 if ((h->current != NULL) && (h->th == NULL) &&
911 (NULL != h->client)) 920 (NULL != h->client))
912 { 921 {
913 timeout = GNUNET_TIME_absolute_get_remaining (h->current->timeout); 922 timeout = GNUNET_TIME_absolute_get_remaining (h->current->timeout);