[PATCH 2/2 v2] openpty: use TIOCGPTPEER to open slave side fd

Joseph Myers joseph@codesourcery.com
Mon Aug 28 12:22:00 GMT 2017


On Mon, 28 Aug 2017, Christian Brauner wrote:

> +  /* Try to allocate slave fd solely based on master fd first. */
> +  slave = ioctl (master, TIOCGPTPEER, O_RDWR | O_NOCTTY);

You still need the #ifdef.  openpty is used on non-Linux systems, and the 
oldest kernel headers supported for building glibc are 3.2.

-- 
Joseph S. Myers
joseph@codesourcery.com



More information about the Libc-alpha mailing list