diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-24 14:33:06 +0100 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2020-03-24 14:33:06 +0100 |
commit | 75b8ce467ec35eea4d063f6bd85460253edf3d4f (patch) | |
tree | e285478a6d7de46a34974d398e88fd572ac5b25e | |
parent | Ram issues (diff) | |
download | 42-cub3d-75b8ce467ec35eea4d063f6bd85460253edf3d4f.tar.gz 42-cub3d-75b8ce467ec35eea4d063f6bd85460253edf3d4f.tar.bz2 42-cub3d-75b8ce467ec35eea4d063f6bd85460253edf3d4f.tar.xz 42-cub3d-75b8ce467ec35eea4d063f6bd85460253edf3d4f.tar.zst 42-cub3d-75b8ce467ec35eea4d063f6bd85460253edf3d4f.zip |
Ram issues fixed
-rw-r--r-- | src/ft_raycasting.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/ft_raycasting.c b/src/ft_raycasting.c index e83c8f7..1804118 100644 --- a/src/ft_raycasting.c +++ b/src/ft_raycasting.c @@ -178,21 +178,21 @@ void pthread_join(tid[0], 0x0); pthread_join(tid[1], 0x0); x = 0; - y = 0; while (x < 2) { + y = 0; while (y < cl->wlist.y_size) { - free(cl->rlist.fc_tex_x_tab[x][y]); - free(cl->rlist.fc_tex_y_tab[x][y]); + ft_memdel((void*)&cl->rlist.fc_tex_x_tab[x][y]); + ft_memdel((void*)&cl->rlist.fc_tex_y_tab[x][y]); y++; } - free(cl->rlist.fc_tex_x_tab[x]); - free(cl->rlist.fc_tex_y_tab[x]); + ft_memdel((void*)&cl->rlist.fc_tex_x_tab[x]); + ft_memdel((void*)&cl->rlist.fc_tex_y_tab[x]); x++; } - free(cl->rlist.fc_tex_x_tab); - free(cl->rlist.fc_tex_y_tab); + ft_memdel((void*)&cl->rlist.fc_tex_x_tab); + ft_memdel((void*)&cl->rlist.fc_tex_y_tab); ft_memdel((void*)&cl->rlist.tex_x_tab); ft_memdel((void*)&cl->rlist.row_dist_tab); ft_memdel((void*)&cl->rlist.wall_t_tab); |