-
Notifications
You must be signed in to change notification settings - Fork 0
/
get_next_line.h
33 lines (27 loc) · 1.36 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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* get_next_line.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: nkawaguc <nkawaguc@student.42tokyo.jp> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/05/03 20:02:43 by nkawaguc #+# #+# */
/* Updated: 2024/06/28 00:35:31 by nkawaguc ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef GET_NEXT_LINE_H
# define GET_NEXT_LINE_H
# include <unistd.h>
# include <stdlib.h>
# include <limits.h>
# ifndef BUFFER_SIZE
# define BUFFER_SIZE 1024
# endif
// # define DEBUG
char *get_next_line(int fd);
int buf_init(char **buf);
void *gnl_realloc(void *ptr, size_t new_size, size_t old_size);
int gnl_strncat(char **dst, const char *src, int *line_size, int *cat_size);
int gnl_read(int fd, char **line, int *line_size, char *buf);
void gnl_bzero(void *buf, size_t size);
#endif