ft_tabdel.c 1.1 KB

12345678910111213141516171819202122232425262728293031
  1. /* ************************************************************************** */
  2. /* */
  3. /* ::: :::::::: */
  4. /* ft_tabdel.c :+: :+: :+: */
  5. /* +:+ +:+ +:+ */
  6. /* By: mazimi <marvin@42.fr> +#+ +:+ +#+ */
  7. /* +#+#+#+#+#+ +#+ */
  8. /* Created: 2016/11/29 16:51:44 by mazimi #+# #+# */
  9. /* Updated: 2016/11/29 16:58:45 by mazimi ### ########.fr */
  10. /* */
  11. /* ************************************************************************** */
  12. #include "../libft.h"
  13. /*
  14. ** free each lines of the chart
  15. ** free global chart
  16. */
  17. void ft_tabdel(char **tabe)
  18. {
  19. int i;
  20. i = -1;
  21. if (tabe == NULL)
  22. return ;
  23. while (tabe[++i] != NULL)
  24. ft_strdel(&tabe[i]);
  25. free(tabe);
  26. tabe = NULL;
  27. }