ft_lstclear fonctionne avec une function dell null, joinfree free les deux elements, gnl dup l'element qui sera free par joinfree

This commit is contained in:
hugogogo
2021-06-27 13:31:43 +02:00
parent f1ce5b8b9e
commit 26147eeeeb
6 changed files with 9 additions and 8 deletions

View File

@@ -11,13 +11,13 @@
/* ************************************************************************** */
/*
** allocate count * size byte of memory and
** return a pointer to the allocated memory
**
** exemple allocation for 5 integers with malloc then calloc :
** a = (int *)malloc(5 * sizeof(int)); //5*4bytes = 20 bytes
** free(a);
** a = (int *)calloc(5, sizeof(int));
**
** allocate count * size byte of memory and
** return a pointer to the allocated memory
*/
/*