aboutsummaryrefslogtreecommitdiffstats
path: root/contrib
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2019-11-01 12:34:06 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2019-11-01 12:34:06 +0000
commit5b6d0857950eec979662af72e72ce4101ac2671d (patch)
tree200c6cb7a6011058f4c56fe7271e4b8c2fcc3d24 /contrib
parent0194245dcdbecfb34088339689668fd6c1111cb8 (diff)
downloadrspamd-5b6d0857950eec979662af72e72ce4101ac2671d.tar.gz
rspamd-5b6d0857950eec979662af72e72ce4101ac2671d.zip
[Minor] Rdns: Update loop timestamp if it is cheap
Diffstat (limited to 'contrib')
-rw-r--r--contrib/librdns/rdns_ev.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/contrib/librdns/rdns_ev.h b/contrib/librdns/rdns_ev.h
index aad34abda..3827bcde2 100644
--- a/contrib/librdns/rdns_ev.h
+++ b/contrib/librdns/rdns_ev.h
@@ -162,6 +162,7 @@ rdns_libev_add_timer (void *priv_data, double after, void *user_data)
if (ev != NULL) {
ev_timer_init (ev, rdns_libev_timer_event, after, after);
ev->data = user_data;
+ ev_now_update_if_cheap ((struct ev_loop *)priv_data);
ev_timer_start ((struct ev_loop *)priv_data, ev);
}
return (void *)ev;
@@ -184,6 +185,7 @@ rdns_libev_add_periodic (void *priv_data, double after,
cbdata->ev = ev;
ev_timer_init (ev, rdns_libev_periodic_event, after, after);
ev->data = cbdata;
+ ev_now_update_if_cheap ((struct ev_loop *)priv_data);
ev_timer_start ((struct ev_loop *)priv_data, ev);
}
else {
@@ -211,6 +213,7 @@ rdns_libev_repeat_timer (void *priv_data, void *ev_data)
{
ev_timer *ev = (ev_timer *)ev_data;
if (ev != NULL) {
+ ev_now_update_if_cheap ((struct ev_loop *)priv_data);
ev_timer_again ((struct ev_loop *)priv_data, ev);
}
}