summaryrefslogtreecommitdiffstats
path: root/libc/stdio/puts.c
diff options
context:
space:
mode:
author"Steven J. Hill" <sjhill@realitydiluted.com>2006-02-26 03:57:14 +0000
committer"Steven J. Hill" <sjhill@realitydiluted.com>2006-02-26 03:57:14 +0000
commit9921832fa13cef31006cfa69bc5574636c36ac0f (patch)
tree4faa87a1fbc9842126d3bdc61c0d64285ebcc849 /libc/stdio/puts.c
parent292e2d7a707449b531422d37cec4608d304da24e (diff)
downloaduClibc-alpine-9921832fa13cef31006cfa69bc5574636c36ac0f.tar.bz2
uClibc-alpine-9921832fa13cef31006cfa69bc5574636c36ac0f.tar.xz
Merge from trunk.
Diffstat (limited to 'libc/stdio/puts.c')
-rw-r--r--libc/stdio/puts.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/libc/stdio/puts.c b/libc/stdio/puts.c
index 3a510325b..08525b2f6 100644
--- a/libc/stdio/puts.c
+++ b/libc/stdio/puts.c
@@ -7,6 +7,9 @@
#include "_stdio.h"
+libc_hidden_proto(__fputc_unlocked)
+libc_hidden_proto(fputs_unlocked)
+
int puts(register const char * __restrict s)
{
register FILE *stream = stdout; /* This helps bcc optimize. */
@@ -20,9 +23,9 @@ int puts(register const char * __restrict s)
* then we could have a newline in the buffer of an LBF stream. */
/* Note: Nonportable as fputs need only return nonnegative on success. */
- if ((n = __fputs_unlocked(s, stream)) != EOF) {
+ if ((n = fputs_unlocked(s, stream)) != EOF) {
++n;
- if (__fputc_unlocked_internal('\n', stream) == EOF) {
+ if (__fputc_unlocked('\n', stream) == EOF) {
n = EOF;
}
}