diff options
author | Nick Mathewson <nickm@torproject.org> | 2019-09-17 18:58:28 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2019-09-17 18:58:28 -0400 |
commit | 324e01372ca618727ffdedd8e590c8f11f44b09c (patch) | |
tree | cae3f34f205835bddd2f3714a05bb4d2e96e839a | |
parent | ba7079fddf282f70085c3879c4e192f1af8bb578 (diff) | |
parent | 484710f25be73d18fefa1e03339c9247e8ec7337 (diff) | |
download | tor-324e01372ca618727ffdedd8e590c8f11f44b09c.tar.gz tor-324e01372ca618727ffdedd8e590c8f11f44b09c.zip |
Merge branch 'maint-0.2.9' into release-0.2.9
-rw-r--r-- | changes/ticket31673 | 3 | ||||
-rw-r--r-- | src/common/compat.c | 8 |
2 files changed, 8 insertions, 3 deletions
diff --git a/changes/ticket31673 b/changes/ticket31673 new file mode 100644 index 0000000000..3b2bb4a46e --- /dev/null +++ b/changes/ticket31673 @@ -0,0 +1,3 @@ + o New system requirements (build system): + - Do not include the deprecated <sys/sysctl.h> on Linux or Windows system. + Closes 31673; diff --git a/src/common/compat.c b/src/common/compat.c index ee3bf0fd50..e99abcb16d 100644 --- a/src/common/compat.c +++ b/src/common/compat.c @@ -27,9 +27,6 @@ #ifdef HAVE_SYS_TYPES_H #include <sys/types.h> #endif -#ifdef HAVE_SYS_SYSCTL_H -#include <sys/sysctl.h> -#endif #ifdef HAVE_SYS_STAT_H #include <sys/stat.h> #endif @@ -70,6 +67,11 @@ #include <sys/capability.h> #endif +/* Now deprecated in Linux GLIBC */ +#if defined(HAVE_SYS_SYSCTL_H) && !defined(_WIN32) && !defined(__linux__) +#include <sys/sysctl.h> +#endif + #ifdef _WIN32 #include <conio.h> #include <wchar.h> |