From: Florian Forster Date: Wed, 1 Jul 2009 12:56:17 +0000 (+0200) Subject: src/common.c: More reliable error reporting in `parse_values'. X-Git-Tag: collectd-4.6.4~10 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=c5470f98e71c4f73e3b2f85d17c21d24fccaf156;p=collectd.git src/common.c: More reliable error reporting in `parse_values'. --- diff --git a/src/common.c b/src/common.c index 1af2f144..95c3dce0 100644 --- a/src/common.c +++ b/src/common.c @@ -805,7 +805,11 @@ int parse_values (char *buffer, value_list_t *vl, const data_set_t *ds) dummy = NULL; if (i >= vl->values_len) + { + /* Make sure i is invalid. */ + i = vl->values_len + 1; break; + } if (i == -1) {