![]() |
![]() |
![]() |
![]() |
Get a fully qualified pathname for a file
#include <unistd.h> int ttyname_r( int fildes, char* name, size_t namesize );
libc
The ttyname_r() function stores the null-terminated pathname of the terminal associated with the file descriptor fildes in the character array referenced by name. The array is namesize characters long and should have space for the name and the terminating NULL character.
Zero for success, or an error number.
Safety: | |
---|---|
Cancellation point | No |
Interrupt handler | No |
Signal handler | Yes |
Thread | Yes |
ctermid(), errno, setsid(), ttyname()
![]() |
![]() |
![]() |
![]() |