build: add libavltree, libcommon & libheap dependencies
Otherwise it can break on very parallel builds since collectd link time
arrives before one or more of these were built.
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
Otherwise it can break on very parallel builds since collectd link time
arrives before one or more of these were built.
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
Add test-suite logs to .gitignore
collectd.conf: order plugins alphabetically again
bind: fix zone count check
Merge branch 'collectd-5.4' into collectd-5.5
src/daemon/common.c: Fix off-by-one error in escape_slashes().
Partial cherry-pick of 0cba91923be9326224f8434e4aae7691f7b6dad1.
Partial cherry-pick of 0cba91923be9326224f8434e4aae7691f7b6dad1.
properly handle error cases when kvm_read fails (#1094)
don't report inodes if fs doesn't provide f_files and f_ffree
write_redis plugin: Call freeReplyObject() for each redisReply.
barometer plugin: Fix "Allocator sizeof operand mismatch" warning.
write_sensu plugin: Fix debug message.
It still referenced the variables, which have been removed in
1c4008c3216edbc9c7cbeffd1c597c9b32e8f64d.
It still referenced the variables, which have been removed in
1c4008c3216edbc9c7cbeffd1c597c9b32e8f64d.
write_sensu plugin: Fix memory leak.
turbostat plugin: Fix "Undefined allocation of 0 bytes (CERT MEM04-C; CWE-131)" warning.
openvpn plugin: Fix "Dead assignment" warning.
Merge branch 'collectd-5.4' into collectd-5.5
src/utils_cmd_flush.c: Fix memory leak.
src/utils_rrdcreate.c: Fix memory leak.
src/utils_ignorelist.c: Fix memory leak.
Turns out, regfree(3) cleans up the memory allocated by regcomp(3), but
not the pointer itself.
Turns out, regfree(3) cleans up the memory allocated by regcomp(3), but
not the pointer itself.
src/utils_cmd_putval.c: Fix memory leak.
utils_cache plugin: Fix memory leak.
rrdtool plugin: Add assertion.
This helps the static code analysis to figure out that memory is not
leaking after all.
This helps the static code analysis to figure out that memory is not
leaking after all.
powerdns plugin: Fix memory leak.
While at it, replace the powerdns_config_add_string() function.
While at it, replace the powerdns_config_add_string() function.
memcachec plugin: Fix memory leak.
java plugin: Fix memory leak.
ipvs plugin: Fix memory leak.
gmond plugin: Fix memory leak.
curl_xml plugin: Fix memory leak.
curl_json plugin: Fix memory leak.
curl plugin: Fix memory leak.
collectdmon: Fix memory leak.
apache plugin: Fix memory leak.
src/utils_cache.c: Fix two memory leaks.
* Free "times" pointer if it is not returned to the user.
* Free (re)alloc'ed pointers when strdup() fails.
* Free "times" pointer if it is not returned to the user.
* Free (re)alloc'ed pointers when strdup() fails.
snmp plugin: Fix "Assigned value is garbage or undefined" warning.
src/utils_latency.c: Fix "Assigned value is garbage or undefined" warning.
threshold plugin: Fix "Dead assignment" warnings.
Merge branch 'collectd-5.4' into collectd-5.5
modbus plugin: Make sure variable is initialized.
This was introduced by the merge
(09c6a320f3cb36b5dbb2c2ce43858f33be7acf9b).
This was introduced by the merge
(09c6a320f3cb36b5dbb2c2ce43858f33be7acf9b).
stats plugin: Link with libm (-lm).
Fixes a bug reported by @Tenzer:
symbol lookup error: /usr/lib/collectd/statsd.so: undefined symbol: log
Fixes a bug reported by @Tenzer:
symbol lookup error: /usr/lib/collectd/statsd.so: undefined symbol: log
tail plugin: Make sure variable is initialized.
This was introduced by the merge
(09c6a320f3cb36b5dbb2c2ce43858f33be7acf9b).
This was introduced by the merge
(09c6a320f3cb36b5dbb2c2ce43858f33be7acf9b).
Fix "Undefined allocation of 0 bytes (CERT MEM04-C; CWE-131)" warnings.
threshold plugin: Fix "Dead increment" warnings.
Fix "Argument with 'nonnull' attribute passed null" warnings.
Merge branch 'collectd-5.4' into collectd-5.5
threshold plugin: Fix "Dead assignment" warning.
ted plugin: Fix "Dead assignment" warning.
tail_csv plugin: Fix "Dead assignment" warning.
tail plugin: Fix "Dead assignment" warning.
snmp plugin: Fix "Dead assignment" warning.
powerdns plugin: Fix "Dead assignment" warning.
ping plugin: Fix "Dead assignment" warning.
onewire plugin: Fix "Dead assignment" warning.
openvpn plugin: Fix "Dead assignment" warning.
ntpd plugin: Fix "Dead assignment" warning.
network plugin: Fix "Dead assignment" warning.
modbus plugin: Fix "Dead assignment" warning.
onewire plugin: Fix "Dead assignment" warning.
nfs plugin: Fix handling of servers with 42 or 44 fields.
battery plugin: Fix file descriptor leak.
src/libcollectdclient/client.c: Fix "Dead assignment" warning.
gmond plugin: Fix handling of COUNTER and ABSOLUTE data sources.
email plugin: Fix "Dead assignment" warning.
src/daemon/filter_chain.c: Fix "Dead assignment" warning.
curl_json plugin: Fix "Dead assignment" warning.
amqp plugin: Fix "Dead assignment" warning.
src/utils_avltree.c: Add assertions to rotate_{left,right}().
clang's static code analysis thought that x->right / x->left could be NULL,
reporting false positives. Let's see if this fixes it.
clang's static code analysis thought that x->right / x->left could be NULL,
reporting false positives. Let's see if this fixes it.
snmp plugin: Fix off-by-one array access.
exec plugin: Don't assign variable that is never read.
Merge branch 'collectd-5.4' into collectd-5.5
src/utils_db_query.c: Fix use-after-free.
"r_area->next" was evaluated after "r_area" was freed.
"r_area->next" was evaluated after "r_area" was freed.
barometer plugin: Initialize output arrays.
src/daemon/common.c: Implement strjoin() with memcpy().
The previous implementation used strncat() which has the unfortunate and
unintuitive behavior of copying n+1 bytes to the buffer.
The previous implementation used strncat() which has the unfortunate and
unintuitive behavior of copying n+1 bytes to the buffer.
src/utils_cache.c: Remove incorrect free.
"ce" is not updated / used in this loop, so it would be theoretically
possible for "ce" to be freed twice.
"ce" is not updated / used in this loop, so it would be theoretically
possible for "ce" to be freed twice.
fix openldap segfatult when ldapi is used v2
fix openldap segfatult when ldapi is used
Merge branch 'collectd-5.4' into collectd-5.5
network plugin: Avoid "status may be used uninitialized" warning.
liboconfig: Declare yylex().
email plugin: Fix freeing linked lists.
The previous code essentially did:
for (…; …; ptr = ptr->next)
free (ptr);
The "ptr->next" is a use-after-free.
The previous code essentially did:
for (…; …; ptr = ptr->next)
free (ptr);
The "ptr->next" is a use-after-free.
network plugin: Make sure all memory is freed when the receive thread fails.
Not all that useful (your receive thread just died …) but hopefully
makes the static analysis happy.
Not all that useful (your receive thread just died …) but hopefully
makes the static analysis happy.
Merge branch 'collectd-5.4' into collectd-5.5
Merge remote-tracking branch 'github/pr/1088' into collectd-5.4
src/utils_llist.c: Handle unlikely corner case.
This handles the following (unlikely) case:
(l->head == NULL) && (e == NULL)
In this case, the following code will dereference a NULL pointer:
if (l->head == e)
l->head = e->next;
This handles the following (unlikely) case:
(l->head == NULL) && (e == NULL)
In this case, the following code will dereference a NULL pointer:
if (l->head == e)
l->head = e->next;
src/utils_avltree.c: Rewrite checks in c_avl_pick().
The previous code made the (correct) assumption that "height" is always
greater than zero. This tripped up clang's "scan-build".
This confuses the static analysis in two more places in this file, which
are not as easy to fix :(
The previous code made the (correct) assumption that "height" is always
greater than zero. This tripped up clang's "scan-build".
This confuses the static analysis in two more places in this file, which
are not as easy to fix :(
ceph plugin: Fix allocation size.
barometer plugin: Fix allocation size.
network plugin: Explicitly initialize "fd_num" to zero.
I have the feeling that initialization via memset() and unions in the sockent
structure confuse clang's scan-build.
I have the feeling that initialization via memset() and unions in the sockent
structure confuse clang's scan-build.
notification target: Pass void** to tn_destroy().
The previous call was bad, resulting in errors in free().
The previous call was bad, resulting in errors in free().
perl plugin: Fix invalid free().
notification_meta_t.name is a char[], which we must not free.
notification_meta_t.name is a char[], which we must not free.
liboconfig: Disable some clang warnings.
Hopefully fixes:
scanner.c:4128:17: error: unused function 'yyunput' [-Werror,-Wunused-function]
static void yyunput (int c, register char * yy_bp )
^
scanner.c:4173:16: error: function 'input' is not needed and will not be emitted [-Werror,-Wunneeded-internal-declaration]
static int input (void)
^
2 errors generated.
Hopefully fixes:
scanner.c:4128:17: error: unused function 'yyunput' [-Werror,-Wunused-function]
static void yyunput (int c, register char * yy_bp )
^
scanner.c:4173:16: error: function 'input' is not needed and will not be emitted [-Werror,-Wunneeded-internal-declaration]
static int input (void)
^
2 errors generated.
liboconfig: Declare yyparse().
Should hopefully fix:
oconfig.c:68:12: error: implicit declaration of function 'yyparse' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
status = yyparse ();
^
Should hopefully fix:
oconfig.c:68:12: error: implicit declaration of function 'yyparse' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
status = yyparse ();
^
In rrd synchronous file creation use lock_file
to prevent the creation of the same file at the same time multiple times
and obtain a corrupt rrd file.
to prevent the creation of the same file at the same time multiple times
and obtain a corrupt rrd file.
Allow empty Plugin blocks.
Allow empty Plugin blocks.
use counter type for Innodb_buffer_pool_pages_flushed
Fix 64 bit check issue, running the preprocessor does not honour CFLAGS which holds the relevant -m64
Corrected text in README
Merge branch 'collectd-5.4' into collectd-5.5
Conflicts:
src/write_redis.c
Conflicts:
src/write_redis.c
Revert "contrib/redhat/collectd.spec: added bison and flex"
This reverts commit 38203b1c8d8a8e5e567d7f6783dd8b88a2487070.
A misunderstanding about which tarball to use with the RPM specfile led
us here. See #1079 for the whole conversation.
This reverts commit 38203b1c8d8a8e5e567d7f6783dd8b88a2487070.
A misunderstanding about which tarball to use with the RPM specfile led
us here. See #1079 for the whole conversation.
configure: turbostat: check for MSR_PKG_C10_RESIDENCY symbol
Older versions of `asm/msr-index.h` don't have all the symbol needed to
build the turbostat plugin. Checking for MSR_PKG_C10_RESIDENCY seems to
guarantee we have a recent enough `asm/msr-index.h`.
Fixes #1075
Older versions of `asm/msr-index.h` don't have all the symbol needed to
build the turbostat plugin. Checking for MSR_PKG_C10_RESIDENCY seems to
guarantee we have a recent enough `asm/msr-index.h`.
Fixes #1075
collectd.conf.pod: update libyajl URL
Fixes #1081
Thanks to @msalmonse for pointing this out!
Fixes #1081
Thanks to @msalmonse for pointing this out!