ttyslot man page on OPENSTEP

Man page or keyword search:  
man Server   1419 pages
apropos Keyword Search (all sections)
Output format
OPENSTEP logo
[printable version]


TTYNAME(3P)							   TTYNAME(3P)

NAME
       ttyname, isatty - find name of a terminal

SYNOPSIS
       #include <unistd.h>

       char *ttyname(int fd)

       int isatty(int fd)

(ALSO AVAILABLE IN BSD)
       int ttyslot(void);

DESCRIPTION
       Ttyname	returns	 a  pointer  to	 the  null-terminated path name of the
       terminal device associated with file descriptor fd.

       Isatty returns 1	 if  fd	 is  associated	 with  a  terminal  device,  0
       otherwise.

       Ttyslot	returns	 the  number  of the entry in the ttys(5) file for the
       control terminal of the	current	 process.   Ttyslot  is	 not  a	 POSIX
       function.

RETURN VALUE
       The  ttyname  function returns a NULL pointer if fd is not a valid file
       descriptor associated with a terminal or	 if  the  pathname  cannot  be
       determined.

       Ttyslot	returns	 0  if	`/etc/ttys'  is	 inaccessible  or if it cannot
       determine the control terminal.

FILES
       /dev/∗
       /etc/ttys

SEE ALSO
       ioctl(2), ttys(5)

BUGS
       The return value points to static data whose content is overwritten  by
       each call.

7th Edition			 May 15, 1985			   TTYNAME(3P)
[top]
                             _         _         _ 
                            | |       | |       | |     
                            | |       | |       | |     
                         __ | | __ __ | | __ __ | | __  
                         \ \| |/ / \ \| |/ / \ \| |/ /  
                          \ \ / /   \ \ / /   \ \ / /   
                           \   /     \   /     \   /    
                            \_/       \_/       \_/ 
More information is available in HTML format for server OPENSTEP

List of man pages available for OPENSTEP

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net