Open System Services Programmer's Guide

}
/* Position the paper to top of form again. */
CC = CONTROL(filenum, /* send control code to printer */
1, /* forms control mode */
0 /* top of form control code */
);
if (_status_ne(CC)) {
fprintf(stderr, "Illegal control code to printer: %s\n",\
printer);
exit(1);
}
fclose(infile); /* close input file */
FILE_CLOSE_(filenum); /* close printer file */
exit(0);
}
OSS I/O Management Functions
Table 26 (page 233) displays information about each OSS function that you can use to manage
I/O. The columns of the table contain the following:
OSS Function
The name of the function and a brief description.
OSS Notes
Notes about the OSS implementation of the function. The note “Can return extended errors
means that the function can return errors that are HP extensions to the XPG4 specification.
Refer to the function’s reference page for further information.
Guardian Notes
Notes about using the function from a Guardian process.
The information in this table is only a summary of the information in the reference page for a
function. For details, refer to the reference pages either online or in the Open System Services
Library Calls Reference Manual.
NOTE: To determine which RVUs support an OSS function, see Appendix A (page 438).
Table 26 OSS I/O Functions
Guardian NotesOSS NotesOSS Function
cfgetispeed()
Gets the input baud rate for a
terminal.
cfgetospeed()
Gets the output baud rate for a
terminal.
Does not affect baud rate.cfsetispeed()
Sets the input baud rate for a terminal.
Does not affect baud rate.cfsetospeed()
Sets the output baud rate for a
terminal.
For Guardian TNS processes, it returns
an empty string and errno is set to
ENOTOSS.
If the parameter is a null pointer, the
string is stored in an internal static
area and the address is returned. The
next call to this function overwrites the
contents of the internal static area.
ctermid()
Generates the pathname for a
controlling terminal.
Can return extended errors.
Can return extended errors.fpathconf()
OSS I/O Management Functions 233