projects
/
collectd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(from parent 1:
ebb558d
)
Merge pull request #3298 from rubenk/contextswitch-nosysctl-h
author
Matthias Runge
<mrunge@redhat.com>
Fri, 11 Oct 2019 06:59:29 +0000
(08:59 +0200)
committer
GitHub
<noreply@github.com>
Fri, 11 Oct 2019 06:59:29 +0000
(08:59 +0200)
Only include <sys/sysctl.h> when needed
src/contextswitch.c
patch
|
blob
|
history
diff --git
a/src/contextswitch.c
b/src/contextswitch.c
index
cf3d3da
..
d23d071
100644
(file)
--- a/
src/contextswitch.c
+++ b/
src/contextswitch.c
@@
-26,11
+26,8
@@
#include "plugin.h"
#include "utils/common/common.h"
-#if
def HAVE_SYS_SYSCTL_H
+#if
defined(HAVE_SYSCTLBYNAME) && defined(HAVE_SYS_SYSCTL_H)
#include <sys/sysctl.h>
-#endif
-
-#if HAVE_SYSCTLBYNAME
/* no global variables */
/* #endif HAVE_SYSCTLBYNAME */