Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

fseek(S)

getc(S)

setbuf(S)



     UNGETC(S)                XENIX System V                 UNGETC(S)



     Name
          ungetc - Pushes character back into input stream.

     Syntax
          #include <stdio.h>

          int ungetc (c, stream)
          char c;
          FILE *stream;

     Description
          ungetc pushes the character c back on an input stream.  The
          character will be returned by the next getc call on that
          stream.  ungetc returns c.

          One character of pushback is guaranteed provided something
          has been read from the stream and the stream is actually
          buffered.  Attempts to push EOF are rejected.

          fseek(S) erases all memory of pushed back characters.

     See Also
          fseek(S), getc(S), setbuf(S)

     Diagnostics
          ungetc returns EOF if it can't push a character back.





























     Page 1                                           (printed 8/7/87)



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026