find the slot in the utmp file of the current user
cc . . . -lc
int ttyslot ()
The ttyslot function
returns the index of the current user's entry in the
This is accomplished by
the name of the terminal associated with the standard
input, the standard output, or the error output (0, 1 or 2).
A value of -1 is returned if an error was encountered while
searching for the terminal name or if none of the above
file descriptors is associated with a terminal device.
The ttyslot routine
has been withdrawn from XPG3.
© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003