variable extern environ fonction avec getenv et export ok

This commit is contained in:
hugogogo
2021-11-25 19:45:41 +01:00
parent 80410e6d81
commit ef3e91be13
10 changed files with 225 additions and 52 deletions

View File

@@ -6,7 +6,7 @@
/* By: lperrey <lperrey@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/10/10 05:01:26 by lperrey #+# #+# */
/* Updated: 2021/10/10 07:37:29 by lperrey ### ########.fr */
/* Updated: 2021/11/25 19:01:13 by hulamy ### ########.fr */
/* */
/* ************************************************************************** */
@@ -14,8 +14,11 @@
int builtin_env(int argc, char *argv[], t_all *c) // WIP
{
extern char **environ;
(void)argc;
(void)argv;
ft_putendl_arr_fd(c->envp, 1);
//ft_putendl_arr_fd(c->envp, 1);
ft_putendl_arr_fd(environ, 1);
return (0);
}