From d68e54b7ab5132c4b4b2c1da6367dec96dd9f455 Mon Sep 17 00:00:00 2001 From: Corey Farrell Date: Sat, 18 Nov 2017 21:25:50 -0500 Subject: [PATCH] res_snmp: Declare RONLY if net-snmp headers do not. Some net-snmp builds do not provide the RONLY declare, only NETSNMP_OLDAPI_RONLY. Map RONLY to NETSNMP_OLDAPI_RONLY to get around this error. Change-Id: Ida5c7ad9406515825485c4d3b4a34fd6ad0da577 --- res/snmp/agent.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/res/snmp/agent.c b/res/snmp/agent.c index 9d1528dde9..7cd8955597 100644 --- a/res/snmp/agent.c +++ b/res/snmp/agent.c @@ -63,6 +63,10 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") #include #include +#if !defined(RONLY) && defined(NETSNMP_OLDAPI_RONLY) +#define RONLY NETSNMP_OLDAPI_RONLY +#endif + #include "asterisk/paths.h" /* need ast_config_AST_SOCKET */ #include "asterisk/channel.h" #include "asterisk/logger.h" -- 2.47.2