getttyent, getttynam, setttyent, endttyent - get ttys file entry


   #include <ttyent.h>

   struct ttyent *getttyent(void);

   struct ttyent *getttynam(const char *name);

   int setttyent(void);

   int endttyent(void);


   These  functions  provide  an  interface  to the file _PATH_TTYS (e.g.,

   The function setttyent() opens the file or rewinds it if already open.

   The function endttyent() closes the file.

   The function getttynam() searches for a  given  terminal  name  in  the
   file.  It returns a pointer to a ttyent structure (description below).

   The  function  getttyent() opens the file _PATH_TTYS (if necessary) and
   returns the first entry.  If the file is already open, the next  entry.
   The ttyent structure has the form:

       struct ttyent {
           char *ty_name;     /* terminal device name */
           char *ty_getty;    /* command to execute, usually getty */
           char *ty_type;     /* terminal type for termcap */
           int   ty_status;   /* status flags */
           char *ty_window;   /* command to start up window manager */
           char *ty_comment;  /* comment field */

   ty_status can be:

   #define TTY_ON     0x01  /* enable logins (start ty_getty program) */
   #define TTY_SECURE 0x02  /* allow UID 0 to login */


   For   an   explanation   of   the  terms  used  in  this  section,  see

   │InterfaceAttributeValue                 │
   │getttyent(), setttyent(), │ Thread safety │ MT-Unsafe race:ttyent │
   │endttyent(), getttynam()  │               │                       │


   Not in POSIX.1.  Present on the BSDs, and perhaps other systems.


   Under Linux, the file /etc/ttys, and the functions described above, are
   not used.


   ttyname(3), ttyslot(3)


   This page is part of release 4.09 of the Linux  man-pages  project.   A
   description  of  the project, information about reporting bugs, and the
   latest    version    of    this    page,    can     be     found     at

More Linux Commands

putwin(3ncurses) - miscellaneous curses utility routines....
The unctrl routine returns a character string which is a printable representation of the character c, ignoring attributes. Control characters are displayed in t

csinhl(3) - complex hyperbolic sine - Linux manual page.....
The complex hyperbolic sine function is defined as: csinh(z) = (exp(z)-exp(-z))/2 VERSIONS These functions first appeared in glibc in version 2.1. CONFORMING TO

XpEndPage(3x) - Indicates the end of a print page. (ManPage)
XpEndPage signals the end of a print page, and causes window to be unmapped. All resulting page data is assembled and combined with data previously sent by XpPu

set_menu_grey(3menu) - color and attribute control for menus
The function set_menu_fore sets the foreground attribute of menu. This is the highlight used for selected menu items. menu_fore returns the foreground attribute

audit_delete_rule_data(3) - Delete audit rule (Man Page)....
audit_delete_rule_data is used to delete rules that are currently loaded in the kernel. To delete a rule, you must set up the rules identical to the one being d

fabs(3) - absolute value of floating-point number (ManPage)
These functions return the absolute value of the floating-point number x. RETURN VALUE These functions return the absolute value of x. If x is a NaN, a NaN is r

wcstok(3) - split wide-character string into tokens.........
The wcstok() function is the wide-character equivalent of the strtok(3) function, with an added argument to make it multithread-safe. It can be used to split a

perl5124delta(1) what is new for perl v5.12.4 (Man Page)....
This document describes differences between the 5.12.3 release and the 5.12.4 release. If you are upgrading from an earlier release such as 5.12.2, first read p

gnutls_x509_crt_get_key_id(3) - API function (Man Page).....
gnutls_x509_crt_get_key_id.3 - This function will return a unique ID the depends on the public key parameters. This ID can be used in checking whether a certifi

XSetModifierMapping(3) - manipulate keyboard encoding and ke
The XChangeKeyboardMapping function defines the symbols for the specified number of KeyCodes starting with first_keycode. The symbols for KeyCodes outside this

y1l(3) - Bessel functions of the second kind (Man Page).....
The y0() and y1() functions return Bessel functions of x of the second kind of orders 0 and 1, respectively. The yn() function returns the Bessel function of x

gnutls_rsa_params_export_pkcs1(3) - API function (Man Page)
This function will export the given RSA parameters to a PKCS1 RSAPublicKey structure. If the buffer provided is not long enough to hold the output, then GNUTLS_

We can't live, work or learn in freedom unless the software we use is free.