LeonorMalaga / gt_datalib

Práctica 2 del Taller de Git y GitHub de 42 Málaga
https://view.genial.ly/63a443410483340018b52bed/presentation-42-taller-de-git-y-github
0 stars 1 forks source link

dll_purge #31

Closed LeonorMalaga closed 3 months ago

LeonorMalaga commented 3 months ago

void dll_purge(t_dlist *list, void data) { t_dlist *aux;

if (dll_empty(*list))
    return ;
aux = *list;
while (aux)
{
    if (aux->data == data)
        dll_remove(list, aux);
    aux = aux->next;
}

}