From dfbedbb90052b3d818bbe71dd70c06b83aeaba72 Mon Sep 17 00:00:00 2001 From: kinou-p Date: Wed, 15 Jun 2022 18:32:36 +0200 Subject: [PATCH] norm --- srcs/parsing/check_color_texture.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/srcs/parsing/check_color_texture.c b/srcs/parsing/check_color_texture.c index f812977..84c75d6 100644 --- a/srcs/parsing/check_color_texture.c +++ b/srcs/parsing/check_color_texture.c @@ -6,7 +6,7 @@ /* By: apommier +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2022/06/11 01:00:17 by apommier #+# #+# */ -/* Updated: 2022/06/15 18:16:40 by apommier ### ########.fr */ +/* Updated: 2022/06/15 18:32:06 by apommier ### ########.fr */ /* */ /* ************************************************************************** */ @@ -150,9 +150,9 @@ int check_texture_color(char **tab, t_data *img) index = 0; next = 0; - while (next_space(tab[next], 0) != '1' && tab[next]) + while (tab && tab[next] && next_space(tab[next], 0) != '1') next++; - if (!tab[next]) + if (!tab || !tab[next]) ft_exit("Error\nBad syntax in map file (identifier)\n", img); while (index < next) {