- Add detailed build and bootstrap instructions to README.md. - Convert all source and header files from .c/.h to .c.md/.h.md. - Add bootstrap.sh script for automated building across version history. - Update Makefile and sources.mk to reflect new markdown-based source organization.
26 lines
305 B
Markdown
26 lines
305 B
Markdown
```c
|
|
#define _POSIX_C_SOURCE 200809L
|
|
|
|
#include <stdlib.h>
|
|
#include <sys/types.h>
|
|
|
|
#include "utils.h"
|
|
|
|
char *
|
|
read_line(FILE *f)
|
|
{
|
|
char *line;
|
|
size_t len;
|
|
ssize_t read;
|
|
|
|
line = NULL;
|
|
len = 0;
|
|
read = getline(&line, &len, f);
|
|
if (-1 == read)
|
|
{
|
|
free(line);
|
|
return (NULL);
|
|
}
|
|
return (line);
|
|
}
|
|
```
|