18 strncat(fname
, getenv("HOME"), 1000);
19 strcat(fname
, "/.term_settings");
20 fd
= open(fname
, O_RDWR
);
21 if(fd
== -1) return 2;
23 if(read(fd
, &t
, sizeof(struct termios
)) != sizeof(struct termios
))
25 if(close(fd
)) return 4;
27 if(tcsetattr(STDIN
, TCSANOW
, &t
)) return 5;
29 if(unlink(fname
)) return 6;