Commit 4aef2fa3 authored by Dan Melnic's avatar Dan Melnic Committed by Facebook GitHub Bot

Add eb_signal_set, eb_timer_set methods to be in sync with libevent

Summary:
Add eb_signal_set, eb_timer_set methods to be in sync with libevent

(Note: this ignores all push blocking failures!)

Reviewed By: kevin-vigor

Differential Revision: D20513498

fbshipit-source-id: be8d5d0ca362bdaa86cc161f481aea93cc757c75
parent 5c4e6238
......@@ -83,6 +83,17 @@ class EventBaseEvent {
event_set(&event_, fd, events, callback, arg);
}
void eb_signal_set(
int signum,
void (*callback)(libevent_fd_t, short, void*),
void* arg) {
event_set(&event_, signum, EV_SIGNAL | EV_PERSIST, callback, arg);
}
void eb_timer_set(void (*callback)(libevent_fd_t, short, void*), void* arg) {
event_set(&event_, -1, 0, callback, arg);
}
void eb_ev_base(EventBase* evb);
EventBase* eb_ev_base() const {
return evb_;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment