1 .\" Copyright (c) 1993 by Thomas Koenig (ig25@rz.uni-karlsruhe.de)
3 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
5 .\" Modified Sat Jul 24 18:42:59 1993 by Rik Faith (faith@cs.unc.edu)
6 .TH PUTS 3 (date) "Linux man-pages (unreleased)"
8 fputc, fputs, putc, putchar, puts \- output of characters and strings
11 .RI ( libc ", " \-lc )
16 .BI "int fputc(int " c ", FILE *" stream );
17 .BI "int putc(int " c ", FILE *" stream );
18 .BI "int putchar(int " c );
20 .BI "int fputs(const char *restrict " s ", FILE *restrict " stream );
21 .BI "int puts(const char *" s );
35 except that it may be implemented as a macro which evaluates
41 .BI "putc(" c ", " stdout ) \fR.
48 without its terminating null byte (\(aq\e0\(aq).
53 and a trailing newline
57 Calls to the functions described here can be mixed with each other and with
58 calls to other output functions from the
60 library for the same output stream.
62 For nonlocking counterparts, see
63 .BR unlocked_stdio (3).
69 return the character written as an
80 return a nonnegative number on success, or
84 For an explanation of the terms used in this section, see
92 Interface Attribute Value
99 T} Thread safety MT-Safe
105 POSIX.1-2001, POSIX.1-2008, C89, C99.
107 It is not advisable to mix calls to output functions from the
109 library with low-level calls to
111 for the file descriptor associated with the same output stream; the results
112 will be undefined and very probably not what you want.
124 .BR unlocked_stdio (3)