MiniDevil
As beautiful as a shell
AST utilities: frees entire AST tree recursively. More...
Include dependency graph for ast_utils.c:AST utilities: frees entire AST tree recursively.
Definition in file ast_utils.c.
Functions | |
| static void | free_args (char **args) |
| Free a string array and its entries. More... | |
| void | free_ast (t_ast *node) |
| Recursively free an entire AST tree. More... | |
|
static |
Free a string array and its entries.
| args | Array to free |
Definition at line 21 of file ast_utils.c.
Referenced by free_ast().
Here is the caller graph for this function:| void free_ast | ( | t_ast * | node | ) |
Recursively free an entire AST tree.
| node | Root of tree to free |
Definition at line 46 of file ast_utils.c.
References t_cmd_node::args, t_ast_data::binary, t_redir_node::cmd, t_ast_data::cmd, t_ast::data, t_redir_node::file, free_args(), t_redir_node::heredoc_fd, t_binary_node::left, NODE_COMMAND, NODE_PIPE, NODE_REDIR_HEREDOC, NODE_REDIR_IN, t_ast_data::redir, t_binary_node::right, and t_ast::type.
Referenced by child_execute(), create_pipe_node(), exec_left_pipe_child(), exec_right_pipe_child(), parse_one_redirection(), parse_pipeline(), process_input(), and process_ui_input().
Here is the call graph for this function:
Here is the caller graph for this function: