tcgetsid()

get process group ID of terminal session 

Function


SYNOPSIS

#include <termios.h>

pid_t tcgetsid(int fildes);


DESCRIPTION

The tcgetsid() function returns the value of the process group ID of the session associated with the terminal.


PARAMETERS

fildes 

Is the file descriptor, which must refer to a terminal.


RETURN VALUES

If successful, tcgetsid() returns the process group ID of the session associated with the terminal. Otherwise, it returns -1 and sets errno one of the following values:

EBADF 

The fildes parameter is not a valid file descriptor.

ENOTTY 

The calling process does not have a controlling terminal, or the file is not the controlling terminal.


CONFORMANCE

UNIX 98


MULTITHREAD SAFETY LEVEL

MT-Safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
getsid(), setpgid(), setsid(), tcgetpgrp()


PTC MKS Toolkit 10.5 Documentation Build 40.