tor_multipath_voip/src/timer.h

13 lines
402 B
C
Raw Permalink Normal View History

2019-05-07 17:18:27 +00:00
#pragma once
#include <sys/timerfd.h>
#include "evt_core.h"
2020-02-24 16:22:22 +00:00
enum DONAR_TIMER_DECISION {
DONAR_TIMER_STOP,
DONAR_TIMER_CONTINUE,
};
typedef enum DONAR_TIMER_DECISION (*timer_cb)(struct evt_core_ctx* ctx, void* user_data);
2019-05-07 17:18:27 +00:00
void init_timer(struct evt_core_ctx* evts);
int set_timeout(struct evt_core_ctx* evts, uint64_t milli_sec, void* ctx, timer_cb cb);
2020-01-20 22:35:02 +00:00
void stop_timer(struct evt_core_ctx* evts);