PT_CHOWNSection: GNU C Library (5)
Index Return to Main Contents
NAMEpt_chown - helper function for grantpt(3), changes ownship and permissions of pseudotty
pt_chown is the helper program for the 'grantpt' function. It is not intended to be run directly from the command line. pt_chown sets the owner, group and access permission of the slave pseudo terminal corresponding to the master pseudo terminal passed on file descriptor so that the pseudo terminal can be used by the calling process. This means programs like 'xterm' and 'screen' do not have to be setuid to get a pty. (There may be other reasons why they need privileges.) If you are using a 2.1 or newer Linux kernel with the 'devptsfs' or `devfs' filesystems providing pty slaves, you don't need this program; otherwise you do. The source for 'pt_chown' is in 'login/programs/pt_chown.c'.
It is installed setuid root.
pt_chown takes no arguments.
pt_chown has the following return codes:
The file descriptor is not a valid master pseudo terminal.
The device is not a character device.
Can't change device owner and group or device permissions.
The owner, group, and permissions were successfully changed.
BUGSReport bugs using the glibcbug script to [email protected]
This document was created by man2html, using the manual pages.
Time: 05:34:00 GMT, December 24, 2015