rad_assert(request->magic == REQUEST_MAGIC);
rad_assert(request->proxy != NULL);
- if (!fr_event_now(el, &now)) gettimeofday(&now, NULL);
+ fr_event_now(el, &now);
request->when = request->proxy_when;
#ifdef WITH_COA
request->next_callback = NULL;
request->child_state = REQUEST_PROXIED;
- gettimeofday(&request->when, NULL);
- home->when = request->when;
request->when.tv_sec += home->ping_timeout;;
INSERT_EVENT(no_response_to_ping, request);
post_proxy_fail_handler(request);
} else {
+ /*
+ * Enforce max_request_time.
+ *
+ * We fail over to another backup home server
+ * when the client re-transmits the request. If
+ * the client doesn't re-transmit, no fail-over
+ * occurs.
+ */
rad_assert(request->ev == NULL);
request->child_state = REQUEST_RUNNING;
wait_a_bit(request);
struct timeval when;
void *fun = NULL;
- if (!fr_event_now(el, &now)) gettimeofday(&now, NULL);
+ fr_event_now(el, &now);
PTHREAD_MUTEX_LOCK(&proxy_mutex);
}
}
- if (!fr_event_now(el, &now)) gettimeofday(&now, NULL);
+ fr_event_now(el, &now);
when = now;
/*