summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2b2a769)
raw | patch | inline | side by side (parent: 2b2a769)
author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Sat, 28 Nov 2015 17:59:17 +0000 (18:59 +0100) | ||
committer | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Sat, 28 Nov 2015 17:59:17 +0000 (18:59 +0100) |
CID 37990
src/mqtt.c | patch | blob | history |
diff --git a/src/mqtt.c b/src/mqtt.c
index 7003fcc63e19b08d775d1c258e058383c3061389..d6bcdce7ec5f5367336ce2f2bea9ee5f919e1db0 100644 (file)
--- a/src/mqtt.c
+++ b/src/mqtt.c
ERROR ("mqtt plugin: Unknown config option: %s", child->key);
}
- tmp = realloc (subscribers, sizeof (*subscribers) * subscribers_num);
+ tmp = realloc (subscribers, sizeof (*subscribers) * (subscribers_num + 1) );
if (tmp == NULL)
{
ERROR ("mqtt plugin: realloc failed.");