diff options
| author | Charles <sircharlesaze@gmail.com> | 2019-08-25 19:33:44 +0200 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2019-08-25 19:33:44 +0200 |
| commit | acb835621713942c075a42c8b8040702b27031cc (patch) | |
| tree | 8cf028d878f96e5ab5b2c2f8699b903a8c49675c | |
| download | get_next_line-acb835621713942c075a42c8b8040702b27031cc.tar.gz get_next_line-acb835621713942c075a42c8b8040702b27031cc.tar.bz2 get_next_line-acb835621713942c075a42c8b8040702b27031cc.zip | |
Initial commit with boilerplate stuff
| -rw-r--r-- | .gitmodules | 3 | ||||
| -rw-r--r-- | author | 1 | ||||
| -rw-r--r-- | get_next_line.c | 14 | ||||
| -rw-r--r-- | get_next_line.h | 9 | ||||
| m--------- | libft | 0 |
5 files changed, 27 insertions, 0 deletions
diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..c3c466b --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "libft"] + path = libft + url = ./libft @@ -0,0 +1 @@ +cacharle diff --git a/get_next_line.c b/get_next_line.c new file mode 100644 index 0000000..0beef4d --- /dev/null +++ b/get_next_line.c @@ -0,0 +1,14 @@ +#include <unistd.h> +#include <stdlib.h> +#include "get_next_line.h" + +int get_next_line(const int fd, char **line) +{ + char buf[BUFF_SIZE]; + + while ((read(fd, buf, BUFF_SIZE)) > 0) + { + + } + return 0; +} diff --git a/get_next_line.h b/get_next_line.h new file mode 100644 index 0000000..efe927b --- /dev/null +++ b/get_next_line.h @@ -0,0 +1,9 @@ +#ifndef GET_NEXT_LINE_H +# define GET_NEXT_LINE_H + +# define NEWLINE 0x0A +# define BUFF_SIZE (1 << 8) + +int get_next_line(const int fd, char **line); + +#endif diff --git a/libft b/libft new file mode 160000 +Subproject 9a2b208985ac7d4644c718ada74770b98eeb459 |
