|
|
1.1 ! root 1: /* ! 2: * This routine is one of the main things ! 3: * in this level of curses that depends on the outside ! 4: * environment. ! 5: */ ! 6: #include "curses.ext" ! 7: /* @(#) _outch.c: 1.1 10/15/83 (1.7 10/27/82) */ ! 8: ! 9: int outchcount; ! 10: ! 11: /* ! 12: * Write out one character to the tty. ! 13: */ ! 14: _outch (c) ! 15: chtype c; ! 16: { ! 17: #ifdef DEBUG ! 18: # ifndef LONGDEBUG ! 19: if (outf) ! 20: if (c < ' ') ! 21: fprintf(outf, "^%c", (c+'@')&0177); ! 22: else ! 23: fprintf(outf, "%c", c&0177); ! 24: # else LONGDEBUG ! 25: if(outf) fprintf(outf, "_outch: char '%s' term %x file %x=%d\n", ! 26: unctrl(c&0177), SP, SP->term_file, fileno(SP->term_file)); ! 27: # endif LONGDEBUG ! 28: #endif DEBUG ! 29: ! 30: outchcount++; ! 31: if (SP && SP->term_file) ! 32: putc (c&0177, SP->term_file); ! 33: else ! 34: putc (c&0177, stdout); ! 35: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.