Programming Guide


Writes a single byte to an open file

int sm_fio_putc(int byte, int file_stream);

An ASCII integer value to write. Attempts to write any other kind of value—for example, a string—yield an error.

A handle to the file to write to, obtained by sm_fio_open.



sm_fio_putc writes the specified integer character—a single byte—to a file opened by sm_fio_open. The value should be the integer value of an ASCII character. Call this function only for file streams opened by sm_fio_open. JPL. Routines that are written in C should call fputc. Do not call Panther and C functions on the same I/O stream.

Be sure to call sm_fio_close on file_stream after you finish writing the data; the actual write operation is not complete until the handle to this file stream is released.