mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
fixed stupid bug in list_destroy
This commit is contained in:
parent
3886637db9
commit
3c7a52834f
1 changed files with 2 additions and 2 deletions
|
@ -30,8 +30,8 @@ void list_destroy(struct list *l)
|
|||
pthread_mutex_lock(&l->lock);
|
||||
|
||||
if (l->destructor) {
|
||||
for (void *e = l->start; e != l->end; e++)
|
||||
l->destructor(e);
|
||||
list_foreach(void *p, l)
|
||||
l->destructor(p);
|
||||
}
|
||||
|
||||
free(l->start);
|
||||
|
|
Loading…
Add table
Reference in a new issue