Platon Technologies
not logged in Login Registration
EnglishSlovak
open source software development celebrating 10 years of open source development! Saturday, October 17, 2026

Diff for libplaton/platon/misc/kbhit.c between version 1.1 and 1.2

version 1.1, 2001/10/05 13:42:11 version 1.2, 2001/10/05 18:14:54
Line 20  int kbhit(void){
Line 20  int kbhit(void){
         if(!init){          if(!init){
                 init=1;                  init=1;
                 if((handle=open("/dev/tty",O_RDWR|O_SYNC))==-1){                  if((handle=open("/dev/tty",O_RDWR|O_SYNC))==-1){
   #if 0
                         fputs("kbhit() ERROR: Cannot read from terminal!\n",stderr);                          fputs("kbhit() ERROR: Cannot read from terminal!\n",stderr);
                         exit(1);  #endif
                           return -1;
                 }                  }
                 else{                  else {
                         tcgetattr(handle,&old_term);                          tcgetattr(handle,&old_term);
                         new_term=old_term;                          new_term=old_term;
                         new_term.c_lflag&=~ICANON;                          new_term.c_lflag&=~ICANON;

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

Platon Group <platon@platon.org> http://platon.org/
Copyright © 2002-2006 Platon Group
Site powered by Metafox CMS
Go to Top