summaryrefslogtreecommitdiffstats
path: root/src/s_com.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/s_com.c')
-rw-r--r--src/s_com.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/s_com.c b/src/s_com.c
index 99b3158..ac23f35 100644
--- a/src/s_com.c
+++ b/src/s_com.c
@@ -112,12 +112,11 @@ t_com
com->rdrfd = 0;
com->rdrpath = NULL;
com->env_fork = NULL;
- if (get_redir(word, &com) != 0)
+ if (p_get_redir(word, &com) != 0)
return (NULL);
- if ((words = p_split_args(word, com->redir)) == NULL)
+ if ((word = p_subst_vars(word, msh)) == NULL)
return (NULL);
- /* TODO: subst vars is before getting words fuck my life */
- if ((words = p_subst_vars(words, msh)) == NULL)
+ if ((words = p_split_args(word, com->redir)) == NULL)
return (NULL);
if ((words = p_subst_home(words, msh)) == NULL)
return (NULL);