[Mplayer-cvslog] CVS: main/linux getch2.c,1.1.1.1,1.2

GEREOFFY arpi_esp at users.sourceforge.net
Sun Jun 3 02:31:43 CEST 2001


Update of /cvsroot/mplayer/main/linux
In directory usw-pr-cvs1:/tmp/cvs-serv11294/linux

Modified Files:
	getch2.c 
Log Message:
FreeBSD support by Vladimir Kushnir vkushnir at Alfacom.net

Index: getch2.c
===================================================================
RCS file: /cvsroot/mplayer/main/linux/getch2.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -r1.1.1.1 -r1.2
*** getch2.c	2001/02/24 20:30:12	1.1.1.1
--- getch2.c	2001/06/03 00:31:41	1.2
***************
*** 202,215 ****
--- 202,227 ----
  void getch2_enable(){
  struct termios tio_new;
+ #ifdef __FreeBSD__
+     ioctl(0,TIOCGETA,&tio_orig); /*  tcgetattr(0,&tio_orig); */
+ #else
      ioctl(0,TCGETS,&tio_orig); /*  tcgetattr(0,&tio_orig); */
+ #endif
      tio_new=tio_orig;
      tio_new.c_lflag &= ~(ICANON|ECHO); /* Clear ICANON and ECHO. */
      tio_new.c_cc[VMIN] = 1;
      tio_new.c_cc[VTIME] = 0;
+ #ifdef __FreeBSD__
+     ioctl(0,TIOCSETA,&tio_new); /*   tcsetattr(0,TCSANOW,&tio_new); */
+ #else
      ioctl(0,TCSETS,&tio_new); /*   tcsetattr(0,TCSANOW,&tio_new); */
+ #endif
  }
  
  void getch2_disable(){
+ #ifdef __FreeBSD__
+     ioctl(0,TIOCSETA,&tio_orig); /*   tcsetattr(0,TCSANOW,&tio_orig); */
+ #else
      ioctl(0,TCSETS,&tio_orig); /*   tcsetattr(0,TCSANOW,&tio_orig); */
+ #endif
  }
  


_______________________________________________
Mplayer-cvslog mailing list
Mplayer-cvslog at lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/mplayer-cvslog



More information about the MPlayer-cvslog mailing list