From 1221e834f49adb91eb0b7443a57274f2611459c2 Mon Sep 17 00:00:00 2001 From: Jakob Kaivo Date: Sat, 23 Feb 2019 15:22:33 -0500 Subject: compile in current environment --- src/fcntl/fcntl.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'src/fcntl/fcntl.c') diff --git a/src/fcntl/fcntl.c b/src/fcntl/fcntl.c index 18288776..b02745e9 100644 --- a/src/fcntl/fcntl.c +++ b/src/fcntl/fcntl.c @@ -2,12 +2,11 @@ #include #include "errno.h" #include "stdarg.h" -#include "nonstd/types.h" #include "nonstd/syscall.h" int fcntl(int fildes, int cmd, ...) { - SCNO(scno, "fcntl", -1); + SYSCALL_NUMBER(scno, "fcntl", -1); int r = -ENOSYS; enum { NONE, INT, FLOCK } arg = NONE; @@ -35,16 +34,16 @@ int fcntl(int fildes, int cmd, ...) } if (arg == NONE) { - r = __libc.syscall(scno, fildes); + r = __syscall(scno, fildes); } else { va_list ap; va_start(ap, cmd); if (arg == INT) { int n = va_arg(ap, int); - r = __libc.syscall(scno, fildes, n); + r = __syscall(scno, fildes, n); } else if (arg == FLOCK) { struct flock *fl = va_arg(ap, struct flock *); - r = __libc.syscall(scno, fildes, fl); + r = __syscall(scno, fildes, fl); } va_end(ap); } -- cgit v1.2.1