29 lines
1.1 KiB
C
29 lines
1.1 KiB
C
|
/* ************************************************************************** */
|
||
|
/* */
|
||
|
/* ::: :::::::: */
|
||
|
/* ft_destroy.c :+: :+: :+: */
|
||
|
/* +:+ +:+ +:+ */
|
||
|
/* By: gtertysh <marvin@42.fr> +#+ +:+ +#+ */
|
||
|
/* +#+#+#+#+#+ +#+ */
|
||
|
/* Created: 2016/11/03 23:41:05 by gtertysh #+# #+# */
|
||
|
/* Updated: 2016/11/04 04:01:33 by gtertysh ### ########.fr */
|
||
|
/* */
|
||
|
/* ************************************************************************** */
|
||
|
|
||
|
#include <stdlib.h>
|
||
|
#include "ft_ultimator.h"
|
||
|
|
||
|
void ft_destroy(char ***factory)
|
||
|
{
|
||
|
while (*factory != 0)
|
||
|
{
|
||
|
while (**factory != 0)
|
||
|
{
|
||
|
free(**factory);
|
||
|
**factory++;
|
||
|
}
|
||
|
free(*factory);
|
||
|
*factory++;
|
||
|
}
|
||
|
}
|