diff --git a/sources/cleanups.c b/sources/cleanups.c index 0250a92..72a1847 100644 --- a/sources/cleanups.c +++ b/sources/cleanups.c @@ -6,18 +6,17 @@ /* By: bgoulard +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/11/09 01:11:01 by bgoulard #+# #+# */ -/* Updated: 2024/11/09 01:11:45 by bgoulard ### ########.fr */ +/* Updated: 2024/11/11 21:30:19 by bgoulard ### ########.fr */ /* */ /* ************************************************************************** */ #include "cub3d_struct.h" - -#include +#include "ft_string.h" static void cleanup_cli(t_cli *cli_ctx) { if (cli_ctx->file) - free(cli_ctx->file); + ft_free((void **)&cli_ctx->file); } static void cleanup_map(t_map *map) diff --git a/sources/main.c b/sources/main.c index a1dca47..2ef363f 100644 --- a/sources/main.c +++ b/sources/main.c @@ -6,7 +6,7 @@ /* By: rparodi +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/10/30 16:30:03 by rparodi #+# #+# */ -/* Updated: 2024/11/11 20:01:31 by rparodi ### ########.fr */ +/* Updated: 2024/11/11 21:34:07 by bgoulard ### ########.fr */ /* */ /* ************************************************************************** */ @@ -59,7 +59,6 @@ void run_cub3d(t_info *info) // - game loop init_mlx_env(info); // - mlx cleanup - (void)info; } int main_cub3d(char *file_arg, t_info *info) @@ -80,7 +79,7 @@ int main_cub3d(char *file_arg, t_info *info) int main(int argc, char *argv[]) { t_info info; - int parsed_args; + int parsed_args; parsed_args = c3_options(&info, argc, argv); if (parsed_args == -1)