home *** CD-ROM | disk | FTP | other *** search
/ minnie.tuhs.org / unixen.tar / unixen / PDP-11 / Trees / V6 / usr / man / man3 / getchar.3 < prev    next >
Encoding:
Text File  |  1975-06-26  |  751 b   |  32 lines

  1. .th GETCHAR III 4/7/73
  2. .sh NAME
  3. getchar \*- read character
  4. .sh SYNOPSIS
  5. .ft B
  6. getchar( )
  7. .br
  8. .ft R
  9. .sh DESCRIPTION
  10. .it Getchar
  11. provides the simplest means of reading characters from
  12. the standard input for C programs.
  13. It returns successive characters until end-of-file,
  14. when it returns ``\\0''.
  15. .s3
  16. Associated with this routine is an external variable
  17. called \fIfin\fR, which is a structure containing
  18. a buffer such as described under \fIgetc\fR (III).
  19. .s3
  20. Generally speaking,
  21. .it getchar
  22. should be used only for the simplest applications;
  23. .it getc
  24. is better when there are multiple input files.
  25. .sh "SEE ALSO"
  26. getc (III)
  27. .sh DIAGNOSTICS
  28. Null character returned on EOF or error.
  29. .sh BUGS
  30. \*-1 should be
  31. returned on EOF; null is a legitimate character.
  32.