Y a exam desoler bb pas le temps de te mettre un vrai commit jtm
This commit is contained in:
parent
5d425048f2
commit
9a87ad7097
13 changed files with 457 additions and 8 deletions
20
libft/main.c
Normal file
20
libft/main.c
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
#include "get_next_line.h"
|
||||
#include <stdio.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
int main(void)
|
||||
{
|
||||
int fd = open("get_next_line.c", O_RDONLY);
|
||||
int i = 0;
|
||||
char *next_line = NULL;
|
||||
while (i < 10000000)
|
||||
{
|
||||
next_line = get_next_line(fd);
|
||||
if (!next_line)
|
||||
return (printf("next_line[%d] = %s\n", i, next_line));
|
||||
printf("next_line[%d] = %s", i, next_line);
|
||||
free(next_line);
|
||||
i++;
|
||||
}
|
||||
return (0);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue