projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'collectd-5.4' into collectd-5.5
[collectd.git]
/
src
/
utils_db_query.c
diff --git
a/src/utils_db_query.c
b/src/utils_db_query.c
index
f29eabc
..
9c84937
100644
(file)
--- a/
src/utils_db_query.c
+++ b/
src/utils_db_query.c
@@
-202,8
+202,9
@@
static int udb_result_submit (udb_result_t *r, /* {{{ */
assert (r != NULL);
assert (r_area->ds != NULL);
assert (((size_t) r_area->ds->ds_num) == r->values_num);
assert (r != NULL);
assert (r_area->ds != NULL);
assert (((size_t) r_area->ds->ds_num) == r->values_num);
+ assert (r->values_num > 0);
- vl.values = (value_t *) calloc (r
_area->ds->d
s_num, sizeof (value_t));
+ vl.values = (value_t *) calloc (r
->value
s_num, sizeof (value_t));
if (vl.values == NULL)
{
ERROR ("db query utils: malloc failed.");
if (vl.values == NULL)
{
ERROR ("db query utils: malloc failed.");