TheSecretOrganization / minishell

MIT License
1 stars 2 forks source link

env with env -i has uninitialised bytes #241

Closed antoineverin closed 7 months ago

antoineverin commented 7 months ago
==766== Use of uninitialised value of size 8
==766==    at 0x110B17: ft_strlen (src/ft_strlen.c:20)
==766==    by 0x110315: ft_putstr_fd (src/ft_putstr_fd.c:17)
==766==    by 0x11021A: ft_putendl_fd (src/ft_putendl_fd.c:17)
==766==    by 0x109A9E: cmd_env (src/builtin/env.c:40)
==766==    by 0x10A6AB: exec_builtin (src/execution/builtin.c:35)
==766==    by 0x10AE5E: dispatch_cmd (src/execution/dispatch.c:60)
==766==    by 0x10ECEE: main (src/main.c:53)
==766==
==766== Syscall param write(buf) contains uninitialised byte(s)
==766==    at 0x49D0887: write (write.c:26)
==766==    by 0x110324: ft_putstr_fd (src/ft_putstr_fd.c:17)
==766==    by 0x11021A: ft_putendl_fd (src/ft_putendl_fd.c:17)
==766==    by 0x109A9E: cmd_env (src/builtin/env.c:40)
==766==    by 0x10A6AB: exec_builtin (src/execution/builtin.c:35)
==766==    by 0x10AE5E: dispatch_cmd (src/execution/dispatch.c:60)
==766==    by 0x10ECEE: main (src/main.c:53)
==766==