line ne se free pas
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/14 18:28:42 by yantoine #+# #+# */
|
||||
/* Updated: 2025/02/25 00:29:27 by yantoine ### ########.fr */
|
||||
/* Updated: 2025/02/25 01:44:31 by yantoine ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
@@ -21,8 +21,6 @@ int check_if_max(t_scene scene, const int to_test, const int max)
|
||||
{
|
||||
(void)scene;
|
||||
if (to_test >= max)
|
||||
{
|
||||
return (0);
|
||||
}
|
||||
return (1);
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/14 01:41:17 by yantoine #+# #+# */
|
||||
/* Updated: 2025/02/22 20:37:46 by yantoine ### ########.fr */
|
||||
/* Updated: 2025/02/25 01:35:19 by yantoine ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
@@ -54,6 +54,7 @@ t_scene load_config(const char *filename)
|
||||
line = get_next_line(fd);
|
||||
if (!line)
|
||||
break ;
|
||||
printf("line: %s\n", line);
|
||||
scene = parsing_line(line, scene);
|
||||
free(line);
|
||||
}
|
||||
|
||||
+1
-3
@@ -6,7 +6,7 @@
|
||||
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/22 18:27:48 by yantoine #+# #+# */
|
||||
/* Updated: 2025/02/22 18:28:45 by yantoine ### ########.fr */
|
||||
/* Updated: 2025/02/25 01:13:20 by yantoine ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
@@ -28,8 +28,6 @@ int isdigit_token(char **tokens)
|
||||
&& tokens[i][j] != '-' \
|
||||
&& tokens[i][j] != ',')
|
||||
{
|
||||
printf("%c\n", tokens[i][j]);
|
||||
printf("%p\n", tokens[i]);
|
||||
return (0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/17 19:54:03 by yantoine #+# #+# */
|
||||
/* Updated: 2025/02/25 00:02:01 by yantoine ### ########.fr */
|
||||
/* Updated: 2025/02/25 02:38:18 by yantoine ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/13 20:02:36 by yantoine #+# #+# */
|
||||
/* Updated: 2025/02/25 00:29:04 by yantoine ### ########.fr */
|
||||
/* Updated: 2025/02/25 00:34:07 by yantoine ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
@@ -238,7 +238,7 @@ char **get_tokens_secure(t_scene scene, const int numObject,
|
||||
int check_tokens(char **tokens, int expected);
|
||||
int isdigit_token(char **tokens);
|
||||
int have_extension(const char *line);
|
||||
int check_if_max(t_scene scene, const int to_test, const int max);
|
||||
int check_if_max(t_scene scene, const int to_test, const int max);
|
||||
|
||||
// Intersection
|
||||
float intersect_cylinder(t_ray ray, t_cylinder cy, t_vec3 *hitNormal);
|
||||
|
||||
+1
-1
@@ -6,7 +6,7 @@
|
||||
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/14 20:23:21 by yantoine #+# #+# */
|
||||
/* Updated: 2025/02/17 21:34:12 by yantoine ### ########.fr */
|
||||
/* Updated: 2025/02/25 02:40:01 by yantoine ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user