home *** CD-ROM | disk | FTP | other *** search
- #ifdef sequent
- #include <stdio.h>
- #include <sgtty.h>
-
- cbreak()
- {
- int i;
- extern int errno;
- struct sgttyb ttystatus;
- char *a;
- /* it is seemingly impossible to get lint to shut
- up about this: */
- a= &ttystatus.sg_ispeed;
- errno=0;
- i=ioctl(0,TIOCGETP,a);
- if(i<0)
- {int me;me=errno;fprintf(stderr,"errno %d\n",me);exit(3);}
-
- #define F ttystatus.sg_flags
- F |= CBREAK;
- i=ioctl(0,TIOCSETP,a);
- if(i<0)
- {int me;me=errno;fprintf(stderr,"errno %d\n",me);exit(4);}
- }
- #else
- cbreak(){}
- #endif
-