X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fdaemon%2Futils_llist.c;h=4265286bdaf899dcb2bba34e97a712876d5455b0;hb=7bfda8d327240ac73297e4449663814dd0594be5;hp=09c9834d066cf6280ed993515adb36adc2176141;hpb=cb314c15d51352ebcc4cfd2bbf1d6a3042c2402f;p=collectd.git diff --git a/src/daemon/utils_llist.c b/src/daemon/utils_llist.c index 09c9834d..4265286b 100644 --- a/src/daemon/utils_llist.c +++ b/src/daemon/utils_llist.c @@ -123,6 +123,9 @@ void llist_remove (llist_t *l, llentry_t *e) { llentry_t *prev; + if ((l == NULL) || (e == NULL)) + return; + prev = l->head; while ((prev != NULL) && (prev->next != e)) prev = prev->next;