

-----------------------------------------------------------------
                           LISTING II
                 INKEY FUNCTION FOR USE WITH SCO XENIX

 
char inkey(chan)
{int chan
int i;
char ch;
    if  (rdchk(chan) > 0)
        {
        i=read(chan, &ch, 1);
        ch = ch & 0xff;

        }
    else
        return (0);
    
    return (ch);
}

  

 

