safe_list: add missing null pointer check in safe_list_del()
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
This commit is contained in:
parent
c434230a76
commit
316e3fb6c2
1 changed files with 2 additions and 1 deletions
|
@ -108,6 +108,7 @@ void safe_list_del(struct safe_list *list)
|
|||
next->i = list->i;
|
||||
list->i->head = &next->i;
|
||||
*tail = next_i;
|
||||
if (next_i)
|
||||
next_i->head = tail;
|
||||
|
||||
list->i = NULL;
|
||||
|
|
Loading…
Reference in a new issue