summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/b_alias.c4
-rw-r--r--src/s_com.c2
2 files changed, 4 insertions, 2 deletions
diff --git a/src/b_alias.c b/src/b_alias.c
index 55b7232..5ca86da 100644
--- a/src/b_alias.c
+++ b/src/b_alias.c
@@ -28,11 +28,13 @@ static void
/* char buff[255][255][ARG_MAX]; */
ptr = msh->alias;
+ i = 0;
while (ptr != NULL)
{
- ft_printf("alias %s='%s'\n", ptr->name, ptr->val);
ptr = ptr->next;
+ i++;
}
+ ft_printf("alias %s='%s'\n", ptr->name, ptr->val);
}
static uint8_t
diff --git a/src/s_com.c b/src/s_com.c
index b899555..28b460f 100644
--- a/src/s_com.c
+++ b/src/s_com.c
@@ -121,7 +121,7 @@ t_com
{
ret = p_subst_alias(nword, TRUE, msh);
while (ret != 0)
- ret = p_subst_alias(nword, TRUE, msh);
+ ret = p_subst_alias(nword, FALSE, msh);
}
p_subst_vars(nword, msh);
if ((words = p_split_args(nword, com->redir)) == NULL)