_tcsetattr.c

Go to the documentation of this file.
00001 /*
00002 posix/_tcsetattr.c
00003 
00004 Created:        June 11, 1993 by Philip Homburg
00005 */
00006 
00007 #define tcsetattr _tcsetattr
00008 #define ioctl _ioctl
00009 #include <errno.h>
00010 #include <termios.h>
00011 #include <sys/ioctl.h>
00012 #include <sys/types.h>
00013 
00014 int tcsetattr(fd, opt_actions, termios_p)
00015 int fd;
00016 int opt_actions;
00017 _CONST struct termios *termios_p;
00018 {
00019   int request;
00020 
00021   switch(opt_actions)
00022   {
00023     case TCSANOW:       request = TCSETS;       break;
00024     case TCSADRAIN:     request = TCSETSW;      break;
00025     case TCSAFLUSH:     request = TCSETSF;      break;
00026     default:            errno = EINVAL;         return(-1);
00027   };
00028   return(ioctl(fd, request, (void *) termios_p));
00029 }

Generated on Fri Apr 14 22:57:27 2006 for minix by  doxygen 1.4.6