OSDN Git Service

Use __typeof instead of adding full prototypes
authorPeter S. Mazinger <ps.m@gmx.net>
Sat, 21 Jan 2006 00:18:02 +0000 (00:18 -0000)
committerPeter S. Mazinger <ps.m@gmx.net>
Sat, 21 Jan 2006 00:18:02 +0000 (00:18 -0000)
libc/misc/internals/__uClibc_main.c
libc/sysdeps/linux/common/__syscall_fcntl.c
libc/sysdeps/linux/common/__syscall_fcntl64.c
libc/sysdeps/linux/common/open.c
libc/sysdeps/linux/common/open64.c

index 7bfe2cc..190263b 100644 (file)
@@ -38,9 +38,9 @@ libc_hidden_proto(fstat)
 libc_hidden_proto(abort)
 libc_hidden_proto(exit)
 
-extern int __libc_open (__const char *__file, int __oflag, ...) __nonnull ((1));
+extern __typeof(open) __libc_open;
 libc_hidden_proto(__libc_open)
-extern int __libc_fcntl (int __fd, int __cmd, ...);
+extern __typeof(fcntl) __libc_fcntl;
 libc_hidden_proto(__libc_fcntl)
 
 #ifndef SHARED
index c7a39bd..3553db5 100644 (file)
 #include <fcntl.h>
 #include <bits/wordsize.h>
 
-extern int __libc_fcntl(int fd, int cmd, ...);
+extern __typeof(fcntl) __libc_fcntl;
 libc_hidden_proto(__libc_fcntl)
 
 #if defined __UCLIBC_HAS_LFS__ && defined __NR_fcntl64
-extern int __libc_fcntl64(int fd, int cmd, ...);
+extern __typeof(fcntl64) __libc_fcntl64;
 libc_hidden_proto(__libc_fcntl64)
 #endif
 
index 34ad2d1..cadeb84 100644 (file)
@@ -12,7 +12,7 @@
 #include <fcntl.h>
 
 #if defined __UCLIBC_HAS_LFS__ && defined __NR_fcntl64
-extern int __libc_fcntl64(int fd, int cmd, ...);
+extern __typeof(fcntl64) __libc_fcntl64;
 libc_hidden_proto(__libc_fcntl64)
 
 #define __NR___syscall_fcntl64 __NR_fcntl64
index d755f36..0db3b00 100644 (file)
@@ -14,7 +14,7 @@
 #include <string.h>
 #include <sys/param.h>
 
-extern int __libc_open(const char *file, int flags, ...);
+extern __typeof(open) __libc_open;
 libc_hidden_proto(__libc_open)
 
 #define __NR___syscall_open __NR_open
index 90837cf..e194f3d 100644 (file)
@@ -14,7 +14,7 @@
 # define O_LARGEFILE   0100000
 #endif
 
-extern int __libc_open (__const char *__file, int __oflag, ...) __nonnull ((1));
+extern __typeof(open) __libc_open;
 libc_hidden_proto(__libc_open)
 
 /* Open FILE with access OFLAG.  If OFLAG includes O_CREAT,