mirror of
https://github.com/fluencelabs/musl
synced 2025-07-07 10:32:06 +00:00
initial check-in, version 0.5.0
This commit is contained in:
8
src/stdio/gets.c
Normal file
8
src/stdio/gets.c
Normal file
@ -0,0 +1,8 @@
|
||||
#include "stdio_impl.h"
|
||||
|
||||
char *gets(char *s)
|
||||
{
|
||||
char *ret = fgets(s, INT_MAX, stdin);
|
||||
if (ret && s[strlen(s)-1] == '\n') s[strlen(s)-1] = 0;
|
||||
return ret;
|
||||
}
|
Reference in New Issue
Block a user