Commit | Line | Data |
---|---|---|
e6817382 BJ |
1 | .TH PUTS 3S |
2 | .SH NAME | |
3 | puts, fputs \- put a string on a stream | |
4 | .SH SYNOPSIS | |
5 | .B #include <stdio.h> | |
6 | .PP | |
7 | .B puts(s) | |
8 | .br | |
9 | .B char *s; | |
10 | .PP | |
11 | .B fputs(s, stream) | |
12 | .br | |
13 | .B char *s; | |
14 | .br | |
15 | .SM | |
16 | .B FILE | |
17 | .B *stream; | |
18 | .SH DESCRIPTION | |
19 | .I Puts | |
20 | copies the null-terminated string | |
21 | .I s | |
22 | to the standard output stream | |
23 | .I stdout | |
24 | and appends a | |
25 | newline character. | |
26 | .PP | |
27 | .I Fputs | |
28 | copies the null-terminated string | |
29 | .I s | |
30 | to the named output | |
31 | .IR stream . | |
32 | .PP | |
33 | Neither routine copies the terminal null character. | |
34 | .SH "SEE ALSO" | |
35 | fopen(3), gets(3), | |
36 | putc(3), printf(3), | |
37 | ferror(3) | |
38 | .br | |
39 | fread(3) for | |
40 | .I fwrite | |
41 | .SH BUGS | |
42 | .I Puts | |
43 | appends a newline, | |
44 | .I fputs | |
45 | does not, all in the name of backward compatibility. |