diff options
Diffstat (limited to 'src/new_token.c')
| -rw-r--r-- | src/new_token.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/new_token.c b/src/new_token.c index 6f49681..c9bd28c 100644 --- a/src/new_token.c +++ b/src/new_token.c @@ -6,11 +6,12 @@ /* By: chuhlig <chuhlig@student.42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/06/27 14:29:44 by dkaiser #+# #+# */ -/* Updated: 2025/01/22 00:41:47 by chuhlig ### ########.fr */ +/* Updated: 2025/01/24 18:46:05 by chuhlig ### ########.fr */ /* */ /* ************************************************************************** */ #include "token.h" +#include "libft.h" t_token *new_token(int type, t_token *previous, t_token *next) { @@ -39,7 +40,7 @@ t_token *new_str_token(char *str, t_token *previous, t_token *next) free(str); return (NULL); } - token->content.string = str; + token->content.string = ft_strdup(str); return (token); } |
