From: Vsevolod Stakhov Date: Thu, 15 Oct 2015 13:03:31 +0000 (+0100) Subject: Add workaround for old libevent. X-Git-Tag: 1.0.6~19 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=5b28b96425b1733068f6ae021eae2d9918a85c6c;p=rspamd.git Add workaround for old libevent. Issue: #400 Reported by: @Nikolay --- diff --git a/src/libutil/util.h b/src/libutil/util.h index f39730b0f..68ee6babc 100644 --- a/src/libutil/util.h +++ b/src/libutil/util.h @@ -407,5 +407,10 @@ gboolean rspamd_constant_memcmp (const guchar *a, const guchar *b, gsize len); #if !defined(LIBEVENT_VERSION_NUMBER) || LIBEVENT_VERSION_NUMBER < 0x02000000UL struct event_base * event_get_base (struct event *ev); #endif +/* CentOS libevent */ +#ifndef evsignal_set +#define evsignal_set(ev, x, cb, arg) \ + event_set((ev), (x), EV_SIGNAL|EV_PERSIST, (cb), (arg)) +#endif #endif