diff options
| author | Alex Richardson <Alexander.Richardson@cl.cam.ac.uk> | 2021-03-18 10:46:55 +0000 |
|---|---|---|
| committer | Simon Ser <contact@emersion.fr> | 2021-04-15 07:34:53 +0000 |
| commit | 34306efeb261f8466ad427a61cdae3272b8bae4d (patch) | |
| tree | 1b5addc317c0303dcaea70044f67cfa1ee571e24 | |
| parent | os-wrappers-test.c: Correctly forward arguments to fcntl (diff) | |
| download | wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.tar wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.tar.gz wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.tar.bz2 wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.tar.lz wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.tar.xz wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.tar.zst wayland-34306efeb261f8466ad427a61cdae3272b8bae4d.zip | |
Change wl_os_dupfd_cloexec minfd to be int
The fcntl() argument is defined to be an int and not a long. This does not
matter on most architectures since the value is passed in registers, but
it causes issues on big-endian architectures that pass variadic arguments
on the stack.
Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk>
Reviewed-by: Simon Ser <contact@emersion.fr>
| -rw-r--r-- | src/wayland-os.c | 2 | ||||
| -rw-r--r-- | src/wayland-os.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/wayland-os.c b/src/wayland-os.c index 93b6f5f..1e4a23d 100644 --- a/src/wayland-os.c +++ b/src/wayland-os.c @@ -73,7 +73,7 @@ wl_os_socket_cloexec(int domain, int type, int protocol) } int -wl_os_dupfd_cloexec(int fd, long minfd) +wl_os_dupfd_cloexec(int fd, int minfd) { int newfd; diff --git a/src/wayland-os.h b/src/wayland-os.h index f51efaa..af37640 100644 --- a/src/wayland-os.h +++ b/src/wayland-os.h @@ -30,7 +30,7 @@ int wl_os_socket_cloexec(int domain, int type, int protocol); int -wl_os_dupfd_cloexec(int fd, long minfd); +wl_os_dupfd_cloexec(int fd, int minfd); ssize_t wl_os_recvmsg_cloexec(int sockfd, struct msghdr *msg, int flags); |
