Skip to content

Commit

Permalink
gh-85984: Add _POSIX_VDISABLE from unistd.h to termios module. (#114985)
Browse files Browse the repository at this point in the history
Signed-off-by: Soumendra Ganguly <soumendraganguly@gmail.com>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
  • Loading branch information
8vasu and gpshead authored Feb 11, 2024
1 parent aeffc7f commit bf75f1b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Added ``_POSIX_VDISABLE`` from C's ``<unistd.h>`` to :mod:`termios`.
7 changes: 4 additions & 3 deletions Modules/termios.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@

#include <termios.h>
#include <sys/ioctl.h>
#if defined(__sun) && defined(__SVR4)
# include <unistd.h> // ioctl()
#endif
#include <unistd.h> // _POSIX_VDISABLE

/* HP-UX requires that this be included to pick up MDCD, MCTS, MDSR,
* MDTR, MRI, and MRTS (apparently used internally by some things
Expand Down Expand Up @@ -1315,6 +1313,9 @@ static struct constant {
#ifdef TIOCTTYGSTRUCT
{"TIOCTTYGSTRUCT", TIOCTTYGSTRUCT},
#endif
#ifdef _POSIX_VDISABLE
{"_POSIX_VDISABLE", _POSIX_VDISABLE},
#endif

/* sentinel */
{NULL, 0}
Expand Down

0 comments on commit bf75f1b

Please sign in to comment.