Update contrib.
3 * Portions Copyright (c) 1990-1999 Nokia Corporation and/or its subsidiary(-ies).
8 * Copyright (c) 1990 The Regents of the University of California.
11 * Redistribution and use in source and binary forms are permitted
12 * provided that the above copyright notice and this paragraph are
13 * duplicated in all such forms and that any documentation,
14 * advertising materials, and other materials related to such
15 * distribution and use acknowledge that the software was developed
16 * by the University of California, Berkeley. The name of the
17 * University may not be used to endorse or promote products derived
18 * from this software without specific prior written permission.
19 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
20 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
21 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
26 <<fputs>>---write a character string in a file or stream
33 int fputs(const char *<[s]>, FILE *<[fp]>);
37 int fputs(<[s]>, <[fp]>)
42 <<fputs>> writes the string at <[s]> (but without the trailing null)
43 to the file or stream identified by <[fp]>.
46 If successful, the result is <<0>>; otherwise, the result is <<EOF>>.
49 ANSI C requires <<fputs>>, but does not specify that the result on
50 success must be <<0>>; any non-negative value is permitted.
52 Supporting OS subroutines required: <<close>>, <<fstat>>, <<isatty>>,
53 <<lseek>>, <<read>>, <<sbrk>>, <<write>>.
62 Write string to a stream.
63 Writes string to the current position of the given stream.
64 On error the function returns EOF.
65 @param s Null-terminated string to be written.
66 @param fp pointer to an open file.
69 fputs (char const *s, FILE * fp)
75 iov.iov_len = uio.uio_resid = strlen (s);
78 return __sfvwrite (fp, &uio);