summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen2000-06-19 18:25:49 +0000
committerEric Andersen2000-06-19 18:25:49 +0000
commit5e29c6ffce509bc492a2acc4dd4102ac96d0f515 (patch)
treef507bd1431eb6ca52ece3266494e0549cb01d862
parenta15cd0be34c81f445be6a2c2234ab0d355b71fba (diff)
downloadbusybox-5e29c6ffce509bc492a2acc4dd4102ac96d0f515.zip
busybox-5e29c6ffce509bc492a2acc4dd4102ac96d0f515.tar.gz
Make swaponoff compile cleanly under both libc5 and libc6.
-Erik
-rw-r--r--swaponoff.c6
-rw-r--r--util-linux/swaponoff.c6
2 files changed, 8 insertions, 4 deletions
diff --git a/swaponoff.c b/swaponoff.c
index 83aadd0..223436c 100644
--- a/swaponoff.c
+++ b/swaponoff.c
@@ -25,11 +25,13 @@
#include "internal.h"
#include <stdio.h>
#include <sys/mount.h>
-#include <sys/swap.h>
#include <mntent.h>
#include <dirent.h>
-#include <fstab.h>
#include <errno.h>
+#include <linux/unistd.h>
+
+_syscall2(int, swapon, const char *, path, int, flags);
+_syscall1(int, swapoff, const char *, path);
static int whichApp;
diff --git a/util-linux/swaponoff.c b/util-linux/swaponoff.c
index 83aadd0..223436c 100644
--- a/util-linux/swaponoff.c
+++ b/util-linux/swaponoff.c
@@ -25,11 +25,13 @@
#include "internal.h"
#include <stdio.h>
#include <sys/mount.h>
-#include <sys/swap.h>
#include <mntent.h>
#include <dirent.h>
-#include <fstab.h>
#include <errno.h>
+#include <linux/unistd.h>
+
+_syscall2(int, swapon, const char *, path, int, flags);
+_syscall1(int, swapoff, const char *, path);
static int whichApp;