diff --git a/srcs/ft_free.c b/srcs/ft_free.c index aa9889c..cf8cadf 100644 --- a/srcs/ft_free.c +++ b/srcs/ft_free.c @@ -6,7 +6,7 @@ /* By: thrieg < thrieg@student.42mulhouse.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2025/11/19 15:44:05 by thrieg #+# #+# */ -/* Updated: 2025/12/08 15:34:11 by thrieg ### ########.fr */ +/* Updated: 2025/12/08 15:53:31 by thrieg ### ########.fr */ /* */ /* ************************************************************************** */ @@ -104,7 +104,7 @@ void free(void *ptr) pthread_mutex_unlock(&g_mut); return; // we didn't allocate this ptr } + pthread_mutex_unlock(&g_mut); if (g_state.patern) ft_memset(ptr, g_state.patern ^ 0xFF, header->size); // doesn't need to lock because we only modify the user pointer and the user doesn't have accces to it yet - pthread_mutex_unlock(&g_mut); }