Diff for /gforth/Attic/io.c between versions 1.17 and 1.20

version 1.17, 1996/09/23 20:41:59 version 1.20, 1997/03/04 22:09:54
Line 28 Line 28
 #include "config.h"  #include "config.h"
 #include <unistd.h>  #include <unistd.h>
   
 #ifdef apollo  #if defined(apollo) || defined(_WIN32)
 #define _POSIX_VERSION  #define _POSIX_VERSION
 #endif  #endif
   
Line 71 Line 71
   
 /* System V machines use termio. */  /* System V machines use termio. */
 #if !defined (_POSIX_VERSION)  #if !defined (_POSIX_VERSION)
 #  if defined (USG) || defined (hpux) || defined (Xenix) || defined (sgi) || defined (DGUX) || defined (ultrix) || defined (Solaris)  #  if defined (USG) || defined (hpux) || defined (Xenix) || defined (sgi) || defined (DGUX) || defined (ultrix) || defined (Solaris) || defined(_WIN32)
 #    undef NEW_TTY_DRIVER  #    undef NEW_TTY_DRIVER
 #    define TERMIO_TTY_DRIVER  #    define TERMIO_TTY_DRIVER
 #    include <termio.h>  #    include <termio.h>
Line 615  long key_avail (stream) Line 615  long key_avail (stream)
   
   if(!terminal_prepped)  prep_terminal();    if(!terminal_prepped)  prep_terminal();
   
 #if defined (FIONREAD)  #ifndef _WIN32
   result = ioctl (tty, FIONREAD, &chars_avail);    result = ioctl (tty, FIONREAD, &chars_avail);
   #else
     {
        fd_set selin;
        static int now[2] = { 0 , 0 };
        int res;
   
        FD_ZERO(&selin);
        FD_SET(tty, &selin);
        chars_avail=select(1, &selin, NULL, NULL, now);
     }
 #endif  #endif
   
   if(chars_avail == -1L)    if(chars_avail == -1L)
Line 755  signal_throw(int sig) Line 765  signal_throw(int sig)
 }  }
   
 UCell cols=80;  UCell cols=80;
 #ifdef MSDOS  #if defined(MSDOS) || defined (_WIN32)
 UCell rows=25;  UCell rows=25;
 #else  #else
 UCell rows=24;  UCell rows=24;

Removed from v.1.17  
changed lines
  Added in v.1.20


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>