diff options
author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2014-05-14 18:43:20 +0000 |
---|---|---|
committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2014-05-14 18:43:20 +0000 |
commit | f61d78fb42d2662643e7f0dbdcb97adbc2589dbc (patch) | |
tree | 9b915379eafaa12682f45d6cb1f41e94fcb12a36 /services/mesh.c | |
parent | 697291b66c481c617cf9875497e2189bc4a4b096 (diff) |
Notes
Diffstat (limited to 'services/mesh.c')
-rw-r--r-- | services/mesh.c | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/services/mesh.c b/services/mesh.c index 5c66caf3236d2..a8cb115ab935f 100644 --- a/services/mesh.c +++ b/services/mesh.c @@ -321,6 +321,8 @@ void mesh_new_client(struct mesh_area* mesh, struct query_info* qinfo, } #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_insert(&mesh->all, &s->node); log_assert(n != NULL); @@ -390,6 +392,8 @@ mesh_new_callback(struct mesh_area* mesh, struct query_info* qinfo, } #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_insert(&mesh->all, &s->node); log_assert(n != NULL); @@ -422,7 +426,7 @@ mesh_new_callback(struct mesh_area* mesh, struct query_info* qinfo, } void mesh_new_prefetch(struct mesh_area* mesh, struct query_info* qinfo, - uint16_t qflags, uint32_t leeway) + uint16_t qflags, time_t leeway) { struct mesh_state* s = mesh_area_find(mesh, qinfo, qflags&BIT_RD, 0); #ifdef UNBOUND_DEBUG @@ -450,6 +454,8 @@ void mesh_new_prefetch(struct mesh_area* mesh, struct query_info* qinfo, } #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_insert(&mesh->all, &s->node); log_assert(n != NULL); @@ -657,6 +663,8 @@ void mesh_detach_subs(struct module_qstate* qstate) RBTREE_FOR(ref, struct mesh_state_ref*, &qstate->mesh_info->sub_set) { #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_delete(&ref->s->super_set, &lookup); log_assert(n != NULL); /* must have been present */ @@ -693,6 +701,8 @@ int mesh_attach_sub(struct module_qstate* qstate, struct query_info* qinfo, } #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_insert(&mesh->all, &sub->node); log_assert(n != NULL); @@ -701,6 +711,8 @@ int mesh_attach_sub(struct module_qstate* qstate, struct query_info* qinfo, /* set new query state to run */ #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_insert(&mesh->run, &sub->run_node); log_assert(n != NULL); @@ -749,6 +761,8 @@ int mesh_state_attachment(struct mesh_state* super, struct mesh_state* sub) } #ifdef UNBOUND_DEBUG n = +#else + (void) #endif rbtree_insert(&super->sub_set, &subref->node); log_assert(n != NULL); /* we checked above if statement, the reverse @@ -878,8 +892,8 @@ mesh_send_reply(struct mesh_state* m, int rcode, struct reply_info* rep, m->s.env->mesh->num_reply_addrs--; end_time = *m->s.env->now_tv; timeval_subtract(&duration, &end_time, &r->start_time); - verbose(VERB_ALGO, "query took %d.%6.6d sec", - (int)duration.tv_sec, (int)duration.tv_usec); + verbose(VERB_ALGO, "query took %lld.%6.6d sec", + (long long)duration.tv_sec, (int)duration.tv_usec); m->s.env->mesh->replies_sent++; timeval_add(&m->s.env->mesh->replies_sum_wait, &duration); timehist_insert(m->s.env->mesh->histogram, &duration); @@ -1124,7 +1138,7 @@ mesh_stats(struct mesh_area* mesh, const char* str) timeval_divide(&avg, &mesh->replies_sum_wait, mesh->replies_sent); log_info("average recursion processing time " - "%d.%6.6d sec", (int)avg.tv_sec, (int)avg.tv_usec); + "%lld.%6.6d sec", (long long)avg.tv_sec, (int)avg.tv_usec); log_info("histogram of recursion processing times"); timehist_log(mesh->histogram, "recursions"); } |