summaryrefslogtreecommitdiffstats
path: root/src/ft_echo.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ft_echo.c')
-rw-r--r--src/ft_echo.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ft_echo.c b/src/ft_echo.c
index 1ca8fc2..e8ef75c 100644
--- a/src/ft_echo.c
+++ b/src/ft_echo.c
@@ -24,17 +24,17 @@ ft_echo(char **com, uint8_t n)
i = 1;
fd = 1;
if (!com[1])
- ft_putendl_fd("", fd);
+ ft_dprintf(fd, "\n");
else if (!ft_strncmp(com[1], "-n", ft_strlen(com[1])))
i = 2;
while (i < n)
{
- ft_putstr_fd(ft_strtrim(com[i], "\""), fd);
+ ft_dprintf(fd, "%s", ft_strtrim(com[i], "\""));
if (i != n - 1)
- ft_putchar_fd(' ', fd);
+ ft_dprintf(fd, " ");
i++;
}
if (ft_strncmp(com[1], "-n", ft_strlen(com[1])))
- ft_putchar_fd('\n', fd);
+ ft_dprintf(fd, "\n");
return (0);
}