NULL);
}
-/**
- * Compute when we should save the hostlist entries the next time;
- * then schedule the task accordingly.
- */
-static void
-schedule_hostlist_saving_task ();
-
/**
* Task that checks if we should try to download a hostlist.
* If so, we initiate the download, otherwise we schedule
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
_("Scheduled saving of hostlists\n"));
save_hostlist_file ( GNUNET_NO );
- /*schedule_hostlist_saving_task ();*/
-}
-
-/**
- * Compute when we should save the hostlist entries the next time;
- * then schedule the task accordingly.
- */
-static void
-schedule_hostlist_saving_task ()
-{
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- _("Hostlists will be saved to file again in %llums\n"),
+ _("Hostlists will be saved to file again in %llums\n"),
(unsigned long long) SAVING_INTERVALL.value);
saving_task = GNUNET_SCHEDULER_add_delayed (sched,
SAVING_INTERVALL,
linked_list_head = NULL;
linked_list_tail = NULL;
load_hostlist_file ();
- // schedule_hostlist_saving_task ();
+
+ GNUNET_log (GNUNET_ERROR_TYPE_INFO,
+ _("Hostlists will be saved to file again in %llums\n"),
+ (unsigned long long) SAVING_INTERVALL.value);
+ saving_task = GNUNET_SCHEDULER_add_delayed (sched,
+ SAVING_INTERVALL,
+ &hostlist_saving_task,
+ NULL);
GNUNET_STATISTICS_get (stats,
"hostlist",
#include "gnunet_time_lib.h"
#define MAX_NUMBER_HOSTLISTS 30
-#define SAVING_INTERVALL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 5)
+#define SAVING_INTERVALL GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 30)
/*
* Defines concerning the hostlist quality metric