-
Notifications
You must be signed in to change notification settings - Fork 0
/
get_next_line.h
36 lines (31 loc) · 1.37 KB
/
get_next_line.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* get_next_line.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: jeongble <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/07/06 23:21:27 by jeongble #+# #+# */
/* Updated: 2022/07/22 09:53:13 by jeongble ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef GET_NEXT_LINE_H
# define GET_NEXT_LINE_H
# include <sys/types.h>
# include <stdlib.h>
# include <unistd.h>
# define BUFFER_SIZE 5
typedef struct s_len
{
char buf[BUFFER_SIZE];
ssize_t success;
size_t sol;
size_t len;
size_t new;
} t_info2;
int buf_end(char **str, t_info2 *info);
int fd_error(int fd, char **str, t_info2 *info);
char *get_next_line(int fd);
char *buf_join(char **str, char *buffer, t_info2 *info, int option);
void *ft_memcpy(void *dst, const void *src, size_t n);
#endif