mirror of
https://codeberg.org/ACME-Corporation/cub3d.git
synced 2025-12-06 01:48:08 +01:00
fix: Fixed memory leak
This commit is contained in:
parent
aae5e42b13
commit
3230a60c9f
1 changed files with 1 additions and 2 deletions
|
|
@ -6,7 +6,7 @@
|
||||||
/* By: kcolin <kcolin@42.fr> +#+ +:+ +#+ */
|
/* By: kcolin <kcolin@42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2025/07/17 14:14:30 by kcolin #+# #+# */
|
/* Created: 2025/07/17 14:14:30 by kcolin #+# #+# */
|
||||||
/* Updated: 2025/08/12 14:48:31 by tchampio ### ########.fr */
|
/* Updated: 2025/08/12 14:49:01 by tchampio ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
|
|
@ -64,7 +64,6 @@ int main(int argc, char **argv)
|
||||||
if (argc < 2)
|
if (argc < 2)
|
||||||
return (ft_printf("Error: Missing cub3d file\n"), 1);
|
return (ft_printf("Error: Missing cub3d file\n"), 1);
|
||||||
init_cub3d_data(&data, argv);
|
init_cub3d_data(&data, argv);
|
||||||
data.sprite_list = ft_calloc(sizeof(t_sprite *), MAX_SPRITES);
|
|
||||||
mlx_hook(data.mlx_win, KeyPress, KeyPressMask, keypress_handler, &data);
|
mlx_hook(data.mlx_win, KeyPress, KeyPressMask, keypress_handler, &data);
|
||||||
mlx_hook(data.mlx_win, KeyRelease, KeyReleaseMask,
|
mlx_hook(data.mlx_win, KeyRelease, KeyReleaseMask,
|
||||||
keyrelease_handler, &data);
|
keyrelease_handler, &data);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue