Files
freebsd/lib/libutil
Ed Schouten a08d169679 MFC r183565:
Small cleanups to openpty().

  - Pass O_NOCTTY to posix_openpt(2). This makes the implementation work
    consistently on implementations that make the PTY the controlling TTY
    by default.

  - Call unlockpt() before opening the slave device. POSIX mentions that
    de slave device should only be opened after grantpt() and unlockpt()
    have been called.

  - Replace some redundant code by a label.

As a safety net, add a call to revoke() to unlockpt(). All applications
out there use openpty(), explicitly call revoke() or implement their own
PTY allocation routines. Adding the call to unlockpt() won't hurt, but
will prevent foot-shooting.

Reviewed by:	jhb, kib
Approved by:	re
2008-10-26 21:56:06 +00:00
..
…
…
2008-08-03 16:07:25 +00:00
2007-09-21 14:41:55 +00:00
2008-04-20 16:32:20 +00:00
2007-09-21 14:52:31 +00:00
2006-01-24 04:07:07 +00:00
…
…
2006-11-03 09:03:17 +00:00
…
…
…
2007-09-21 14:52:31 +00:00
2007-09-28 06:35:14 +00:00
2008-10-26 21:56:06 +00:00
2006-09-25 10:05:37 +00:00
…
2005-12-22 00:34:48 +00:00