Module: kamailio Branch: 5.1 Commit: 0b6785d8cffad33ff9ed05b1f345426e81fc0c4c URL: https://github.com/kamailio/kamailio/commit/0b6785d8cffad33ff9ed05b1f345426e...
Author: Henning Westerholt hw@skalatan.de Committer: Henning Westerholt hw@skalatan.de Date: 2019-10-02T12:45:13+02:00
core: fix compile error related to missing T_OPT in older (<2.25) glibc (GH #2087)
(cherry picked from commit 325d1e6d53b3db3265d6f76ec34bb3d6a31419c4)
---
Modified: src/core/resolve.c
---
Diff: https://github.com/kamailio/kamailio/commit/0b6785d8cffad33ff9ed05b1f345426e... Patch: https://github.com/kamailio/kamailio/commit/0b6785d8cffad33ff9ed05b1f345426e...
---
diff --git a/src/core/resolve.c b/src/core/resolve.c index a5ffb86d7d..439435791a 100644 --- a/src/core/resolve.c +++ b/src/core/resolve.c @@ -32,6 +32,13 @@ #include <resolv.h> #include <string.h>
+/* older glibc < 2.25 does not include T_OPT in nameser_compat.h yet */ +#if __GLIBC__ == 2 && __GLIBC_MINOR__ < 25 +#ifndef T_OPT +#define T_OPT ns_t_opt +#endif +#endif + #include "resolve.h" #include "compiler_opt.h" #include "dprint.h"