summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 30afd0b)
raw | patch | inline | side by side (parent: 30afd0b)
author | Dan Fandrich <dan@coneharvesters.com> | |
Mon, 4 Feb 2013 22:59:41 +0000 (23:59 +0100) | ||
committer | Florian Forster <octo@collectd.org> | |
Tue, 5 Feb 2013 06:59:40 +0000 (07:59 +0100) |
Signed-off-by: Florian Forster <octo@collectd.org>
src/plugin.c | patch | blob | history |
diff --git a/src/plugin.c b/src/plugin.c
index 70372342927c9fd2264cb70952fbd308d8317150..942f8bfe50438066adc80b46ac4175c990f9a642 100644 (file)
--- a/src/plugin.c
+++ b/src/plugin.c
pthread_mutex_lock (&write_lock);
i = 0;
- for (q = write_queue_head; q != NULL; q = q->next)
+ for (q = write_queue_head; q != NULL; )
{
+ write_queue_t *q1 = q;
plugin_value_list_free (q->vl);
- sfree (q);
+ q = q->next;
+ sfree (q1);
i++;
}
write_queue_head = NULL;