1
0
mirror of https://github.com/rkd77/elinks.git synced 2024-06-24 00:56:14 +00:00

[timer] set_event_for_timer is only for libevent

This commit is contained in:
Witold Filipczyk 2019-11-16 11:35:18 +01:00
parent d56ad7ceb0
commit e532e348f8

View File

@ -122,11 +122,10 @@ check_timers(timeval_T *last_time)
timeval_copy(last_time, &now);
}
#ifdef USE_LIBEVENT
static void
set_event_for_timer(timer_id_T tm)
{
#ifdef USE_LIBEVENT
struct timeval tv;
struct event *ev = timer_event(tm);
timeout_set(ev, timer_callback, tm);
@ -144,8 +143,8 @@ set_event_for_timer(timer_id_T tm)
#endif
if (timeout_add(ev, &tv) == -1)
elinks_internal("ERROR: timeout_add failed: %s", strerror(errno));
#endif
}
#endif
/* Install a timer that calls @func(@data) after @delay milliseconds.
* Store to *@id either the ID of the new timer, or TIMER_ID_UNDEF if