summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-04-28 16:10:07 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-04-28 16:10:07 +0200
commit2c9ad3343cb47d9a83f39fd0077fadf98a0cf30b (patch)
tree29f71aa0189cbd8cfd38b8a24eb768b3607e489b
parentduped completely envp (diff)
download42-minishell-2c9ad3343cb47d9a83f39fd0077fadf98a0cf30b.tar.gz
42-minishell-2c9ad3343cb47d9a83f39fd0077fadf98a0cf30b.tar.bz2
42-minishell-2c9ad3343cb47d9a83f39fd0077fadf98a0cf30b.tar.xz
42-minishell-2c9ad3343cb47d9a83f39fd0077fadf98a0cf30b.tar.zst
42-minishell-2c9ad3343cb47d9a83f39fd0077fadf98a0cf30b.zip
Ok argv, envp
Diffstat (limited to '')
-rw-r--r--src/ft_m_argv.c2
-rw-r--r--src/ft_m_argv.h2
-rw-r--r--src/ft_s_init.c6
-rw-r--r--src/ft_s_init.h4
-rw-r--r--src/minishell.c4
5 files changed, 9 insertions, 9 deletions
diff --git a/src/ft_m_argv.c b/src/ft_m_argv.c
index 684d396..7b91fbb 100644
--- a/src/ft_m_argv.c
+++ b/src/ft_m_argv.c
@@ -20,7 +20,7 @@
uint8_t
ft_m_argv(int argc,
- const char *argv[],
+ char *const argv[],
t_msh *msh)
{
/* TODO: better argv handling */
diff --git a/src/ft_m_argv.h b/src/ft_m_argv.h
index 2f3260d..783c7e4 100644
--- a/src/ft_m_argv.h
+++ b/src/ft_m_argv.h
@@ -18,7 +18,7 @@
#include "ft_s_struct.h"
uint8_t ft_m_argv(int argc,
- const char *argv[],
+ char *const argv[],
t_msh *msh);
#endif
diff --git a/src/ft_s_init.c b/src/ft_s_init.c
index 463cb0b..26b196b 100644
--- a/src/ft_s_init.c
+++ b/src/ft_s_init.c
@@ -33,7 +33,7 @@ static char
}
static char
- **ft_dupenv(char *envp[])
+ **ft_dupenv(char *const envp[])
{
uint64_t i;
char **nenvp;
@@ -59,8 +59,8 @@ static char
}
t_msh
- *ft_init_msh(const char *argv[],
- char *envp[])
+ *ft_init_msh(char *const argv[],
+ char *const envp[])
{
t_msh *msh;
diff --git a/src/ft_s_init.h b/src/ft_s_init.h
index e860925..bd8edc7 100644
--- a/src/ft_s_init.h
+++ b/src/ft_s_init.h
@@ -16,7 +16,7 @@
#include <stdlib.h>
#include "ft_s_struct.h"
-t_msh *ft_init_msh(const char *argv[],
- char *envp[]);
+t_msh *ft_init_msh(char *const argv[],
+ char *const envp[]);
#endif
diff --git a/src/minishell.c b/src/minishell.c
index b5c07ed..96b51c8 100644
--- a/src/minishell.c
+++ b/src/minishell.c
@@ -23,8 +23,8 @@
int
main(int argc,
- const char *argv[],
- char *envp[])
+ char *const argv[],
+ char *const envp[])
{
t_msh *msh;
int32_t ret;