Closed LeonorMalaga closed 3 months ago
void dll_remove(t_dlist *list, t_dlist elem) { if (dll_empty(list)) return ; if (elem->prev) elem->prev->next = elem->next; else list = elem->next; if (elem->next) elem->next->prev = elem->prev; free(elem); }
void dll_remove(t_dlist *list, t_dlist elem) { if (dll_empty(list)) return ; if (elem->prev) elem->prev->next = elem->next; else list = elem->next; if (elem->next) elem->next->prev = elem->prev; free(elem); }