tcgetattr method

int tcgetattr(
  1. int fd,
  2. termios termios_p
)

Get the parameters associated with the terminal.

Implementation

int tcgetattr(int fd, termios termios_p) {
  if (fd != 0) return -1; // Only stdin supported
  termios_p.c_lflag = io.ioTcgetattr();
  return 0;
}