From 5e327efa642d03bf960716b5058c3d618f5b893f Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Thu, 15 Oct 2020 10:34:16 +0200 Subject: Fixing append redirection labeled has truncate redirection --- src/lexer/utils.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/lexer/utils.c') diff --git a/src/lexer/utils.c b/src/lexer/utils.c index 0d8080c..b16a69a 100644 --- a/src/lexer/utils.c +++ b/src/lexer/utils.c @@ -6,7 +6,7 @@ /* By: nahaddac +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/07/16 08:18:15 by nahaddac #+# #+# */ -/* Updated: 2020/10/10 08:38:46 by cacharle ### ########.fr */ +/* Updated: 2020/10/15 10:32:00 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -22,12 +22,12 @@ enum e_tok tok_assign_tag(char *content) return (TAG_OR); if (content[0] == '|') return (TAG_PIPE); + if (ft_strncmp(content, ">>", 2) == 0) + return (TAG_REDIR_APPEND); if (content[0] == '>') return (TAG_REDIR_OUT); if (content[0] == '<') return (TAG_REDIR_IN); - if (ft_strncmp(content, ">>", 2) == 0) - return (TAG_REDIR_APPEND); if (content[0] == '(') return (TAG_PARENT_OPEN); if (content[0] == ')') -- cgit