From: A. Wilcox Date: Wed, 13 Mar 2019 16:16:11 +0000 (-0500) Subject: fcntl.h: define O_TTY_INIT to 0 X-Git-Tag: v1.1.23~67 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=65c8be380431eebe4d70d130bd38563f8df9a7d7;p=oweals%2Fmusl.git fcntl.h: define O_TTY_INIT to 0 POSIX: "[If] either O_TTY_INIT is set in oflag or O_TTY_INIT has the value zero, open() shall set any non-standard termios structure terminal parameters to a state that provides conforming behavior." The Linux kernel tty drivers always perform initialisation on their devices to set known good termios values during the open(2) call. This means that setting O_TTY_INIT to zero is conforming. --- diff --git a/include/fcntl.h b/include/fcntl.h index f6c192f5..1fba777d 100644 --- a/include/fcntl.h +++ b/include/fcntl.h @@ -36,8 +36,9 @@ 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_TTY_INIT 0 #define O_ACCMODE (03|O_SEARCH) #define O_RDONLY 00