diff options
Diffstat (limited to 'src/parse/parse.c')
| -rwxr-xr-x | src/parse/parse.c | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/src/parse/parse.c b/src/parse/parse.c index 867325b..fe4f9a2 100755 --- a/src/parse/parse.c +++ b/src/parse/parse.c @@ -43,21 +43,24 @@ t_ret *parse(t_ftlst *input) if (tag & TAG_IS_STR && tag & TAG_STICK) ret->rest = ret->rest->next; else + { + ret->rest = ret->rest->next; break; + } } } } - while(ret->ast->cmd_argv != NULL) - { - printf("[%s]\n", ((t_token *)ret->ast->cmd_argv->data)->content); - ret->ast->cmd_argv = ret->ast->cmd_argv->next; - } - while(ret->ast->redirs != NULL) - { - printf("[%s]\n", ((t_token *)ret->ast->redirs->data)->content); - ret->ast->redirs = ret->ast->redirs->next; - } - ast_destroy(ret->ast); - ft_lstdestroy(&ret->rest, (void (*)(void*))token_destroy); + /* while(ret->ast->cmd_argv != NULL) */ + /* { */ + /* printf("[%s]\n", ((t_token *)ret->ast->cmd_argv->data)->content); */ + /* ret->ast->cmd_argv = ret->ast->cmd_argv->next; */ + /* } */ + /* while(ret->ast->redirs != NULL) */ + /* { */ + /* printf("[%s]\n", ((t_token *)ret->ast->redirs->data)->content); */ + /* ret->ast->redirs = ret->ast->redirs->next; */ + /* } */ + /* ast_destroy(ret->ast); */ + /* ft_lstdestroy(&ret->rest, (void (*)(void*))token_destroy); */ return first; } |
