channelpadding: "error: conflicting types for 'event_base_get_method'" on OpenBSD

Build fails on OpenBSD:

In file included from src/or/channelpadding.c:23:
/usr/include/event.h:300: error: conflicting types for 'event_base_get_method'
/usr/local/include/event2/event.h:372: error: previous declaration of 'event_base_get_method' was here
/usr/include/event.h:626: error: conflicting types for 'event_pending'
/usr/local/include/event2/event.h:982: error: previous declaration of 'event_pending' was here
Error 1 in . (Makefile:5155 'src/or/channelpadding.o': @echo "  CC      " src/or/channelpadding.o;depbase=`echo src/or/channelpadding.o ...)

This should fix it:

diff --git a/src/or/channelpadding.c b/src/or/channelpadding.c
index 412165156..f5248e896 100644
--- a/src/or/channelpadding.c
+++ b/src/or/channelpadding.c
@@ -20,7 +20,7 @@
 #include "rephist.h"
 #include "router.h"
 #include "compat_time.h"
-#include <event.h>
+#include <event2/event.h>
 
 STATIC int channelpadding_get_netflow_inactive_timeout_ms(const channel_t *);
 STATIC int channelpadding_send_disable_command(channel_t *);
diff --git a/src/test/test_channelpadding.c b/src/test/test_channelpadding.c
index cffc8d084..6a05fc89b 100644
--- a/src/test/test_channelpadding.c
+++ b/src/test/test_channelpadding.c
@@ -11,7 +11,7 @@
 #include "channelpadding.h"
 #include "compat_libevent.h"
 #include "config.h"
-#include <event.h>
+#include <event2/event.h>
 #include "compat_time.h"
 #include "main.h"
 #include "networkstatus.h"

Trac:
Username: rubiate