-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathenv.c
More file actions
27 lines (24 loc) · 1.06 KB
/
env.c
File metadata and controls
27 lines (24 loc) · 1.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* env.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: almelo <almelo@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/03/07 18:06:38 by almelo #+# #+# */
/* Updated: 2023/04/03 18:40:25 by almelo ### ########.fr */
/* */
/* ************************************************************************** */
#include "minishell.h"
void env(char **envp)
{
size_t i;
i = 0;
while (envp[i])
{
if (ft_strncmp(envp[i], "?", 1) != 0)
ft_putendl_fd(envp[i], STDOUT_FILENO);
i++;
}
exit(0);
}