diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2020-09-08 18:50:11 +0200 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2020-09-08 18:50:11 +0200 |
commit | 4dd10e6f4de22446ea84d7b194d2a18cb6e43c6c (patch) | |
tree | 2768d27ebe01fa5e74b4e6d14c5defdfd501a1d6 /src/s_struct.h | |
parent | static hist, words fix (diff) | |
download | 42-minishell-4dd10e6f4de22446ea84d7b194d2a18cb6e43c6c.tar.gz 42-minishell-4dd10e6f4de22446ea84d7b194d2a18cb6e43c6c.tar.bz2 42-minishell-4dd10e6f4de22446ea84d7b194d2a18cb6e43c6c.tar.xz 42-minishell-4dd10e6f4de22446ea84d7b194d2a18cb6e43c6c.tar.zst 42-minishell-4dd10e6f4de22446ea84d7b194d2a18cb6e43c6c.zip |
Names
Diffstat (limited to '')
-rw-r--r-- | src/s_struct.h | 73 |
1 files changed, 37 insertions, 36 deletions
diff --git a/src/s_struct.h b/src/s_struct.h index 1089dc6..f98f948 100644 --- a/src/s_struct.h +++ b/src/s_struct.h @@ -26,27 +26,27 @@ ** 0: means no redirection */ -typedef struct s_lvars +typedef struct s_lvars { - struct s_lvars *next; - char *name; - char *val; -} t_lvars; + struct s_lvars *next; + char *name; + char *val; +} t_lvars; -typedef struct s_com +typedef struct s_com { - char **argv; - char **env_fork; - char *rdrpath; - char *bin; - int32_t rdrfd; - int8_t redir; -} t_com; + char **argv; + char **env_fork; + char *rdrpath; + char *bin; + int32_t rdrfd; + int8_t redir; +} t_com; -struct s_lpipes +struct s_lpipes { - struct s_com *com; - struct s_lpipes *next; + struct s_com *com; + struct s_lpipes *next; }; /* @@ -57,28 +57,29 @@ struct s_lpipes ** 2: || */ -typedef struct s_line +typedef struct s_line { - struct s_com *com; - struct s_lpipes *pipes; - uint8_t nextif; - struct s_line *next; -} t_line; + char line[4096]; + uint8_t nextif; + struct s_line_block *next; +} t_line; -typedef struct s_msh +typedef struct s_msh { - struct s_line *curr; - struct s_lvars *vars; - char **envp; - char **bu_ref; - char ps[4][1024]; - char env_fork_tmp[128][1024]; - char sqb_ref[FT_ID_SQB_COUNT][4]; - char *shname; - char *cwd; - int32_t fd; - uint8_t (*bu_ptr[FT_BUILTINS_COUNT])(char **, struct s_msh*); - uint8_t ret; -} t_msh; + struct s_line_block *curr; + struct s_com *com; + struct s_lpipes *pipes; + struct s_lvars *vars; + char **envp; + char **bu_ref; + char ps[4][1024]; + char env_fork_tmp[128][1024]; + char sqb_ref[FT_ID_SQB_COUNT][4]; + char *shname; + char *cwd; + int32_t fd; + uint8_t (*bu_ptr[FT_BUILTINS_COUNT])(char **, struct s_msh*); + uint8_t ret; +} t_msh; #endif |