summaryrefslogtreecommitdiffstats
path: root/src/u_vars.c
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-09-19 16:09:41 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-09-19 16:09:41 +0200
commit0ec82dde60df71de23eb553165b40c7407900c8d (patch)
tree6ed20638bfef446ef059cb433070eb22a9f0df29 /src/u_vars.c
parentPrompt stuff (diff)
download42-minishell-0ec82dde60df71de23eb553165b40c7407900c8d.tar.gz
42-minishell-0ec82dde60df71de23eb553165b40c7407900c8d.tar.bz2
42-minishell-0ec82dde60df71de23eb553165b40c7407900c8d.tar.xz
42-minishell-0ec82dde60df71de23eb553165b40c7407900c8d.tar.zst
42-minishell-0ec82dde60df71de23eb553165b40c7407900c8d.zip
qweqwe
Diffstat (limited to 'src/u_vars.c')
-rw-r--r--src/u_vars.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/u_vars.c b/src/u_vars.c
index 97fc580..28040b4 100644
--- a/src/u_vars.c
+++ b/src/u_vars.c
@@ -54,9 +54,12 @@ static void
size_t dstsize,
t_msh *msh)
{
+ char tmp[4];
+
if (ft_strncmp(varname, FT_RET_VAR, 3) == 0)
{
- ft_strlcpy(str, ft_uitoa(msh->ret), 4);
+ ft_uitoa_s(tmp, msh->ret);
+ ft_strlcpy(str, tmp, 4);
}
else if (ft_strncmp(varname, FT_ZER_VAR, 3) == 0)
{