Subversion Repositories Kolibri OS

Rev

Blame | Last modification | View Log | Download | RSS feed

  1. /* Copyright (C) 1996 DJ Delorie, see COPYING.DJ for details */
  2. #include <errno.h>
  3. #include <stddef.h>
  4. #include <termios.h>
  5.  
  6. int
  7. cfsetspeed (struct termios *termiosp, speed_t speed)
  8. {
  9.   /* check arguments */
  10.   if (termiosp == NULL)
  11.     {
  12.       errno = EINVAL;
  13.       return -1;
  14.     }
  15.  
  16.   /* set input and output speed */
  17.   termiosp->c_ispeed = speed;
  18.   termiosp->c_ospeed = speed;
  19.  
  20.   return 0;
  21. }
  22.