summaryrefslogtreecommitdiffstats
path: root/sys-utils/swapon.c
diff options
context:
space:
mode:
authorKarel Zak2017-12-18 13:57:20 +0100
committerKarel Zak2017-12-18 13:57:20 +0100
commitcf9b16f1d408faa63009667329431f7969303220 (patch)
treec85844bf8c0e40713d49a73534bd8da389b6696f /sys-utils/swapon.c
parentlibblkid: (bcache) cleanup magic string definition (diff)
downloadkernel-qcow2-util-linux-cf9b16f1d408faa63009667329431f7969303220.tar.gz
kernel-qcow2-util-linux-cf9b16f1d408faa63009667329431f7969303220.tar.xz
kernel-qcow2-util-linux-cf9b16f1d408faa63009667329431f7969303220.zip
build-sys: don't check for swapon() number of arguments
The syscall swapon() with two arguments is supported since Linux 1.3.2 and it's really long time ago... Let's assume that all libc header files have been already fixed. Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'sys-utils/swapon.c')
-rw-r--r--sys-utils/swapon.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys-utils/swapon.c b/sys-utils/swapon.c
index 6bf67a91f..13437f771 100644
--- a/sys-utils/swapon.c
+++ b/sys-utils/swapon.c
@@ -59,8 +59,7 @@
# define SWAP_FLAG_PRIO_SHIFT 0
#endif
-#ifndef SWAPON_HAS_TWO_ARGS
-/* libc is insane, let's call the kernel */
+#if !defined(HAVE_SWAPON) && defined(SYS_swapon)
# include <sys/syscall.h>
# define swapon(path, flags) syscall(SYS_swapon, path, flags)
#endif