1
0
mirror of https://gitlab.com/80486DX2-66/gists synced 2025-05-31 08:31:41 +05:30

freadln.*: implement reading lines from arbitrary file

This commit is contained in:
2024-03-10 14:39:10 +03:00
parent 7d223427b6
commit e8d66db238
2 changed files with 34 additions and 7 deletions

View File

@@ -26,6 +26,7 @@ enum freadln_status {
return freadln_OK; \
} while (0)
int freadln(char** output, size_t* length_out);
int freadln(FILE* f, char** output, size_t* length_out);
#define finreadln(output, length_out) freadln(stdin, output, length_out)
#endif /* _FREADLN_H */