FPUTS
Section: C Library Functions (3)
Index
Return to Main Contents
BSD mandoc
NAME
fputs
puts
- output a line to a stream
SYNOPSIS
Fd #include <stdio.h>
Ft int
Fn fputs const char *str FILE *stream
Ft int
Fn puts const char *str
DESCRIPTION
The function
Fn fputs
writes the string pointed to by
Fa str
to the stream pointed to by
Fa stream .
The function
Fn puts
writes the string
Fa str ,
and a terminating newline character,
to the stream
stdout
RETURN VALUES
The
Fn fputs
function
returns 0 on success and
EOF
on error;
Fn puts
returns a nonnegative integer on success and
EOF
on error.
ERRORS
- Bq Er EBADF
-
The
Fa stream
supplied
is not a writable stream.
The functions
Fn fputs
and
Fn puts
may also fail and set
errno
for any of the errors specified for the routines
write(2).
SEE ALSO
putc(3),
ferror(3),
stdio(3)
STANDARDS
The functions
Fn fputs
and
Fn puts
conform to
St -ansiC .
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- RETURN VALUES
-
- ERRORS
-
- SEE ALSO
-
- STANDARDS
-
This document was created by
man2html,
using the manual pages.
Time: 19:42:00 GMT, December 25, 2022