summaryrefslogtreecommitdiff
path: root/lib/libc/stdio/puts.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/stdio/puts.c')
-rw-r--r--lib/libc/stdio/puts.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/libc/stdio/puts.c b/lib/libc/stdio/puts.c
new file mode 100644
index 00000000..41024337
--- /dev/null
+++ b/lib/libc/stdio/puts.c
@@ -0,0 +1,9 @@
+#include <stdio.h>
+#include <string.h>
+
+int puts(const char *s)
+{
+ fwrite(s, 1, strlen(s), stdout);
+ fwrite("\n", 1, 1, stdout);
+ return 0;
+}