From 11d2f363077468fdccf58d49cb1d9e30aa9e70e1 Mon Sep 17 00:00:00 2001 From: lperrey Date: Mon, 20 Dec 2021 17:56:35 +0100 Subject: [PATCH] norme headers + add -Werror flag in Makefile --- Makefile | 2 +- headers/minishell_prototypes.h | 10 +++++----- headers/minishell_structs.h | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index ea641cc..a86efaf 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ NAME = minishell CC = clang -CFLAGS = -Wall -Wextra $(INCLUDES) -g # add -Werror, del -g +CFLAGS = -Wall -Wextra -Werror $(INCLUDES) -g # del -g VPATH = $(DIR_SRCS) DIR_SRCS = srcs \ diff --git a/headers/minishell_prototypes.h b/headers/minishell_prototypes.h index a3996de..1d85c13 100644 --- a/headers/minishell_prototypes.h +++ b/headers/minishell_prototypes.h @@ -6,15 +6,15 @@ /* By: lperrey +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2021/10/08 02:59:58 by lperrey #+# #+# */ -/* Updated: 2021/12/20 15:07:39 by hulamy ### ########.fr */ +/* Updated: 2021/12/20 17:49:56 by lperrey ### ########.fr */ /* */ /* ************************************************************************** */ #ifndef MINISHELL_PROTOTYPES_H # define MINISHELL_PROTOTYPES_H -extern int g_switch_heredoc_sigint; -extern char **environ; +extern int g_switch_heredoc_sigint; +extern char **environ; // Init int init(t_all *c, char *argv[]); @@ -97,7 +97,7 @@ void sigint_handler_interactive(int signum); void sigint_handler_heredoc(int signum); // last_exit_status -int set_last_exit_status(int new_value); -int get_last_exit_status(void); +int set_last_exit_status(int new_value); +int get_last_exit_status(void); #endif diff --git a/headers/minishell_structs.h b/headers/minishell_structs.h index 8fe4e6b..feaaa7e 100644 --- a/headers/minishell_structs.h +++ b/headers/minishell_structs.h @@ -6,14 +6,14 @@ /* By: lperrey +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2021/10/08 02:35:52 by lperrey #+# #+# */ -/* Updated: 2021/12/16 06:34:29 by lperrey ### ########.fr */ +/* Updated: 2021/12/20 17:24:45 by lperrey ### ########.fr */ /* */ /* ************************************************************************** */ #ifndef MINISHELL_STRUCTS_H # define MINISHELL_STRUCTS_H -struct s_all; +struct s_all; typedef struct s_token {