Skip to content

Commit 0546f27

Browse files
tachoknightrokhinip
authored andcommitted
sys/sysctl.h is deprecated on Linux and a warning has been added to that file that is treated as an error when compiling; see https://patches-gcc.linaro.org/patch/19443/#34639 for the discussion. This patch adds a guard to prevent the file from being included when compiling on Linux.
Signed-off-by: Kim Topley <[email protected]>
1 parent 0e21537 commit 0546f27

File tree

2 files changed

+1
-2
lines changed

2 files changed

+1
-2
lines changed

src/internal.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,10 +280,9 @@ upcast(dispatch_object_t dou)
280280
#include <sys/mount.h>
281281
#ifdef __ANDROID__
282282
#include <linux/sysctl.h>
283-
#else
284-
#include <sys/sysctl.h>
285283
#endif /* __ANDROID__ */
286284
#if !defined(__linux__)
285+
#include <sys/sysctl.h>
287286
#include <sys/queue.h>
288287
#endif
289288
#include <sys/socket.h>
File renamed without changes.

0 commit comments

Comments
 (0)