fix multiple stdio functions' behavior on zero-length operations
[musl] / src / stdio / fputs.c
1 #include "stdio_impl.h"
2 #include <string.h>
3
4 int fputs(const char *restrict s, FILE *restrict f)
5 {
6         return (int)fwrite(s, strlen(s), 1, f) - 1;
7 }
8
9 weak_alias(fputs, fputs_unlocked);