diff options
Diffstat (limited to 'src/plugins/stats/functions.c')
-rw-r--r-- | src/plugins/stats/functions.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/plugins/stats/functions.c b/src/plugins/stats/functions.c index 71671193..59690dfb 100644 --- a/src/plugins/stats/functions.c +++ b/src/plugins/stats/functions.c | |||
@@ -611,9 +611,7 @@ void init_functions(struct GE_Context * e, | |||
611 | sock = client_connection_create(ectx, | 611 | sock = client_connection_create(ectx, |
612 | cfg); | 612 | cfg); |
613 | lock = MUTEX_CREATE(NO); | 613 | lock = MUTEX_CREATE(NO); |
614 | updateStatValues(NULL); | 614 | cron = gnunet_gtk_get_cron(); |
615 | updateConnectionGoal(NULL); | ||
616 | cron = cron_create(ectx); | ||
617 | cron_add_job(cron, | 615 | cron_add_job(cron, |
618 | &updateStatValues, | 616 | &updateStatValues, |
619 | UPDATE_INTERVAL, | 617 | UPDATE_INTERVAL, |
@@ -624,13 +622,11 @@ void init_functions(struct GE_Context * e, | |||
624 | 5 * cronMINUTES, | 622 | 5 * cronMINUTES, |
625 | 5 * cronMINUTES, | 623 | 5 * cronMINUTES, |
626 | NULL); | 624 | NULL); |
627 | cron_start(cron); | ||
628 | } | 625 | } |
629 | 626 | ||
630 | void done_functions() { | 627 | void done_functions() { |
631 | int i; | 628 | int i; |
632 | 629 | ||
633 | cron_stop(cron); | ||
634 | cron_del_job(cron, | 630 | cron_del_job(cron, |
635 | &updateConnectionGoal, | 631 | &updateConnectionGoal, |
636 | 5 * cronMINUTES, | 632 | 5 * cronMINUTES, |
@@ -639,7 +635,6 @@ void done_functions() { | |||
639 | &updateStatValues, | 635 | &updateStatValues, |
640 | UPDATE_INTERVAL, | 636 | UPDATE_INTERVAL, |
641 | NULL); | 637 | NULL); |
642 | cron_destroy(cron); | ||
643 | MUTEX_DESTROY(lock); | 638 | MUTEX_DESTROY(lock); |
644 | connection_destroy(sock); | 639 | connection_destroy(sock); |
645 | for (i=0;i<lsv_size;i++) | 640 | for (i=0;i<lsv_size;i++) |