From c5470f98e71c4f73e3b2f85d17c21d24fccaf156 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Wed, 1 Jul 2009 14:56:17 +0200 Subject: [PATCH] src/common.c: More reliable error reporting in `parse_values'. --- src/common.c | 4 ++++ 1 file changed, 4 insertions(+) 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) { -- 2.30.2