diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-02-14 03:46:08 +0100 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-02-14 03:46:08 +0100 |
| commit | 9af2885d872de9c60b11159efe0685738031096d (patch) | |
| tree | 813183555eae5d0a84f11d7be3178d07b3d5f9d9 /src/io/ft_next_line.c | |
| parent | adbcf69ed50ea3896d4bbe863ea5d214ae5a0299 (diff) | |
| download | libft-9af2885d872de9c60b11159efe0685738031096d.tar.gz libft-9af2885d872de9c60b11159efe0685738031096d.tar.bz2 libft-9af2885d872de9c60b11159efe0685738031096d.zip | |
Added documentation for all functions and refactored ft_strjoin_free -> ft_strjoinf
Diffstat (limited to 'src/io/ft_next_line.c')
| -rw-r--r-- | src/io/ft_next_line.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/io/ft_next_line.c b/src/io/ft_next_line.c index 51d21ec..0f4cc2c 100644 --- a/src/io/ft_next_line.c +++ b/src/io/ft_next_line.c @@ -6,7 +6,7 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/01/31 10:39:38 by cacharle #+# #+# */ -/* Updated: 2020/01/31 10:39:40 by cacharle ### ########.fr */ +/* Updated: 2020/02/14 03:38:01 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -53,11 +53,11 @@ static int st_read_line(int fd, char **line, char *rest) { ft_strcpy(rest, buf + split_at + 1); buf[split_at] = '\0'; - if ((*line = ft_strjoin_free(*line, buf, 1)) == NULL) + if ((*line = ft_strjoinf(*line, buf, FT_STRJOINF_FST)) == NULL) return (st_free_return(&buf, NULL, FTNL_STATUS_ERROR)); return (st_free_return(&buf, NULL, FTNL_STATUS_LINE)); } - if ((*line = ft_strjoin_free(*line, buf, 1)) == NULL) + if ((*line = ft_strjoinf(*line, buf, FT_STRJOINF_FST)) == NULL) return (st_free_return(&buf, NULL, FTNL_STATUS_ERROR)); } if (ret == -1) |
