musl/src/stdio/puts.c

11 lines
171 B
C
Raw Normal View History

2011-02-12 00:22:29 -05:00
#include "stdio_impl.h"
int puts(const char *s)
{
2011-03-24 22:58:21 -04:00
int r;
FLOCK(stdout);
r = -(fputs(s, stdout) < 0 || putc_unlocked('\n', stdout) < 0);
2011-03-24 22:58:21 -04:00
FUNLOCK(stdout);
return r;
2011-02-12 00:22:29 -05:00
}