MCPcopy Create free account
hub / github.com/acl-dev/acl / timer_fn

Function timer_fn

lib_protocol/samples/http_probe/probe_run.cpp:226–248  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

224}
225
226static void timer_fn(int event_type acl_unused,
227 ACL_EVENT *event acl_unused, void *context)
228{
229 const char *myname = "timer_fn";
230 PROBE_SERVER *server = (PROBE_SERVER *) context;
231
232 server->time_begin = time(NULL);
233
234 server->stream = acl_aio_connect(server->aio, server->addr,
235 server->connect_timeout);
236 if (server->stream == NULL) {
237 msg_error(server, "%s(%d), connect error(%s)",
238 myname, __LINE__, strerror(errno));
239 timer_retry(server);
240 } else {
241 acl_aio_add_connect_hook(server->stream,
242 connect_callback, context);
243 /*
244 acl_aio_add_timeo_hook(server->stream, timeout_callback, ctx);
245 acl_aio_add_close_hook(server->stream, closeed_callback, ctx);
246 */
247 }
248}
249
250void probe_run()
251{

Callers 2

event_timer_callbackFunction · 0.85
event_timer_triggerFunction · 0.85

Calls 4

acl_aio_connectFunction · 0.85
timer_retryFunction · 0.85
acl_aio_add_connect_hookFunction · 0.85
msg_errorFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…