From 6f77f858261ae4c12b3da9a715c76bf529a7509f Mon Sep 17 00:00:00 2001 From: Matthias Wachs Date: Wed, 27 Oct 2010 09:22:31 +0000 Subject: Refactoring GNUNET_time structs --- src/testing/test_testing_topology.c | 4 ++-- src/testing/testing.c | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/testing/test_testing_topology.c b/src/testing/test_testing_topology.c index dd8a16419..8e1fa9c33 100644 --- a/src/testing/test_testing_topology.c +++ b/src/testing/test_testing_topology.c @@ -539,7 +539,7 @@ send_test_messages (void *cls, const struct GNUNET_SCHEDULER_TaskContext * tc) { struct TestMessageContext *pos = cls; - if ((pos == test_messages) && (settle_time.value > 0)) + if ((pos == test_messages) && (settle_time.rel_value > 0)) { topology_connections = 0; GNUNET_TESTING_get_topology (pg, &topology_cb, NULL); @@ -670,7 +670,7 @@ topology_callback (void *cls, &send_test_messages, test_messages); gather_log_data(); #else - if (settle_time.value > 0) + if (settle_time.rel_value > 0) { GNUNET_TESTING_get_topology (pg, &topology_cb, NULL); } diff --git a/src/testing/testing.c b/src/testing/testing.c index f2150697f..7143ba684 100644 --- a/src/testing/testing.c +++ b/src/testing/testing.c @@ -207,7 +207,7 @@ start_fsm (void *cls, /* confirm copying complete */ if (GNUNET_OK != GNUNET_OS_process_status (d->pid, &type, &code)) { - if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).value == 0) + if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).rel_value == 0) { cb = d->cb; d->cb = NULL; @@ -410,7 +410,7 @@ start_fsm (void *cls, /* Fall through */ case SP_HOSTKEY_CREATED: /* wait for topology finished */ - if ((GNUNET_YES == d->dead) || (GNUNET_TIME_absolute_get_remaining(d->max_timeout).value == 0)) + if ((GNUNET_YES == d->dead) || (GNUNET_TIME_absolute_get_remaining(d->max_timeout).rel_value == 0)) { cb = d->cb; d->cb = NULL; @@ -522,7 +522,7 @@ start_fsm (void *cls, case SP_START_ARMING: if (GNUNET_OK != GNUNET_OS_process_status (d->pid, &type, &code)) { - if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).value == 0) + if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).rel_value == 0) { cb = d->cb; d->cb = NULL; @@ -567,7 +567,7 @@ start_fsm (void *cls, /* confirm copying complete */ if (GNUNET_OK != GNUNET_OS_process_status (d->pid, &type, &code)) { - if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).value == 0) + if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).rel_value == 0) { if (NULL != d->dead_cb) d->dead_cb (d->dead_cb_cls, @@ -647,7 +647,7 @@ start_fsm (void *cls, /* confirm copying complete */ if (GNUNET_OK != GNUNET_OS_process_status (d->pid, &type, &code)) { - if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).value == 0) /* FIXME: config update should take timeout parameter! */ + if (GNUNET_TIME_absolute_get_remaining(d->max_timeout).rel_value == 0) /* FIXME: config update should take timeout parameter! */ { cb = d->cb; d->cb = NULL; @@ -1366,7 +1366,7 @@ notify_connect_result (void *cls, ctx->d2->cfg, ctx->d1, ctx->d2, NULL); } } - else if (remaining.value > 0) + else if (remaining.rel_value > 0) { if (ctx->d1core != NULL) { -- cgit v1.2.3