| Index: fusl/include/fcntl.h
|
| diff --git a/fusl/include/fcntl.h b/fusl/include/fcntl.h
|
| index ebd5c30491c1cc6f6bfc146c48c6b8b946fdde51..beb3f5b2073f15f269ffd827d31d8d91c3a488ae 100644
|
| --- a/fusl/include/fcntl.h
|
| +++ b/fusl/include/fcntl.h
|
| @@ -1,5 +1,5 @@
|
| -#ifndef _FCNTL_H
|
| -#define _FCNTL_H
|
| +#ifndef _FCNTL_H
|
| +#define _FCNTL_H
|
|
|
| #ifdef __cplusplus
|
| extern "C" {
|
| @@ -21,29 +21,28 @@ extern "C" {
|
|
|
| #include <bits/fcntl.h>
|
|
|
| -struct flock
|
| -{
|
| - short l_type;
|
| - short l_whence;
|
| - off_t l_start;
|
| - off_t l_len;
|
| - pid_t l_pid;
|
| +struct flock {
|
| + short l_type;
|
| + short l_whence;
|
| + off_t l_start;
|
| + off_t l_len;
|
| + pid_t l_pid;
|
| };
|
|
|
| -int creat(const char *, mode_t);
|
| +int creat(const char*, mode_t);
|
| int fcntl(int, int, ...);
|
| -int open(const char *, int, ...);
|
| -int openat(int, const char *, int, ...);
|
| +int open(const char*, int, ...);
|
| +int openat(int, const char*, int, ...);
|
| int posix_fadvise(int, off_t, off_t, int);
|
| int posix_fallocate(int, off_t, off_t);
|
|
|
| -#define O_SEARCH O_PATH
|
| -#define O_EXEC O_PATH
|
| +#define O_SEARCH O_PATH
|
| +#define O_EXEC O_PATH
|
|
|
| -#define O_ACCMODE (03|O_SEARCH)
|
| -#define O_RDONLY 00
|
| -#define O_WRONLY 01
|
| -#define O_RDWR 02
|
| +#define O_ACCMODE (03 | O_SEARCH)
|
| +#define O_RDONLY 00
|
| +#define O_WRONLY 01
|
| +#define O_RDWR 02
|
|
|
| #define F_OFD_GETLK 36
|
| #define F_OFD_SETLK 37
|
| @@ -63,12 +62,12 @@ int posix_fallocate(int, off_t, off_t);
|
| #define AT_SYMLINK_FOLLOW 0x400
|
| #define AT_EACCESS 0x200
|
|
|
| -#define POSIX_FADV_NORMAL 0
|
| -#define POSIX_FADV_RANDOM 1
|
| +#define POSIX_FADV_NORMAL 0
|
| +#define POSIX_FADV_RANDOM 1
|
| #define POSIX_FADV_SEQUENTIAL 2
|
| -#define POSIX_FADV_WILLNEED 3
|
| -#define POSIX_FADV_DONTNEED 4
|
| -#define POSIX_FADV_NOREUSE 5
|
| +#define POSIX_FADV_WILLNEED 3
|
| +#define POSIX_FADV_DONTNEED 4
|
| +#define POSIX_FADV_NOREUSE 5
|
|
|
| #undef SEEK_SET
|
| #undef SEEK_CUR
|
| @@ -110,31 +109,31 @@ int posix_fallocate(int, off_t, off_t);
|
| #define W_OK 2
|
| #define X_OK 1
|
| #define F_ULOCK 0
|
| -#define F_LOCK 1
|
| +#define F_LOCK 1
|
| #define F_TLOCK 2
|
| -#define F_TEST 3
|
| -
|
| -#define F_SETLEASE 1024
|
| -#define F_GETLEASE 1025
|
| -#define F_NOTIFY 1026
|
| -#define F_CANCELLK 1029
|
| -#define F_SETPIPE_SZ 1031
|
| -#define F_GETPIPE_SZ 1032
|
| -#define F_ADD_SEALS 1033
|
| -#define F_GET_SEALS 1034
|
| -
|
| -#define F_SEAL_SEAL 0x0001
|
| -#define F_SEAL_SHRINK 0x0002
|
| -#define F_SEAL_GROW 0x0004
|
| -#define F_SEAL_WRITE 0x0008
|
| -
|
| -#define DN_ACCESS 0x00000001
|
| -#define DN_MODIFY 0x00000002
|
| -#define DN_CREATE 0x00000004
|
| -#define DN_DELETE 0x00000008
|
| -#define DN_RENAME 0x00000010
|
| -#define DN_ATTRIB 0x00000020
|
| -#define DN_MULTISHOT 0x80000000
|
| +#define F_TEST 3
|
| +
|
| +#define F_SETLEASE 1024
|
| +#define F_GETLEASE 1025
|
| +#define F_NOTIFY 1026
|
| +#define F_CANCELLK 1029
|
| +#define F_SETPIPE_SZ 1031
|
| +#define F_GETPIPE_SZ 1032
|
| +#define F_ADD_SEALS 1033
|
| +#define F_GET_SEALS 1034
|
| +
|
| +#define F_SEAL_SEAL 0x0001
|
| +#define F_SEAL_SHRINK 0x0002
|
| +#define F_SEAL_GROW 0x0004
|
| +#define F_SEAL_WRITE 0x0008
|
| +
|
| +#define DN_ACCESS 0x00000001
|
| +#define DN_MODIFY 0x00000002
|
| +#define DN_CREATE 0x00000004
|
| +#define DN_DELETE 0x00000008
|
| +#define DN_RENAME 0x00000010
|
| +#define DN_ATTRIB 0x00000020
|
| +#define DN_MULTISHOT 0x80000000
|
|
|
| int lockf(int, int, off_t);
|
| #endif
|
| @@ -145,8 +144,8 @@ int lockf(int, int, off_t);
|
| #define F_OWNER_PGRP 2
|
| #define F_OWNER_GID 2
|
| struct f_owner_ex {
|
| - int type;
|
| - pid_t pid;
|
| + int type;
|
| + pid_t pid;
|
| };
|
| #define FALLOC_FL_KEEP_SIZE 1
|
| #define FALLOC_FL_PUNCH_HOLE 2
|
| @@ -161,8 +160,8 @@ int fallocate(int, int, off_t, off_t);
|
| #define fallocate64 fallocate
|
| ssize_t readahead(int, off_t, size_t);
|
| int sync_file_range(int, off_t, off_t, unsigned);
|
| -ssize_t vmsplice(int, const struct iovec *, size_t, unsigned);
|
| -ssize_t splice(int, off_t *, int, off_t *, size_t, unsigned);
|
| +ssize_t vmsplice(int, const struct iovec*, size_t, unsigned);
|
| +ssize_t splice(int, off_t*, int, off_t*, size_t, unsigned);
|
| ssize_t tee(int, int, size_t, unsigned);
|
| #define loff_t off_t
|
| #endif
|
|
|