Go to main content
Oracle Developer Studio 12.5 Man Pages

Exit Print View

Updated: June 2017
 
 

getc(3F)

Name

getc, fgetc - get a character from a logical unit

Synopsis

integer*4 function getc (char)
character char
integer*4 function fgetc (lunit, char)
character char

Description

These functions return the next character from a file associated with a FORTRAN logical unit, bypassing normal FORTRAN I/O.

getc reads from logical unit 5, normally connected to the control terminal input.

The value of each function is a system status code. Zero indicates that no error occurred on the read; -1 indicates that the end of the file was detected. A positive value is either a SunOS system error code or an f77 I/O error code. See perror(3F).

Do not mix normal Fortran I/O with calls to getc or fgetc.

Files

libfsu.a

See Also

intro (2) , getc (3C) , perror (3F)