From d03dea4d7dbfb62ed0c3c21cdd9ad350f0526432 Mon Sep 17 00:00:00 2001 From: Heikki Kallasjoki Date: Wed, 12 Dec 2018 18:08:06 +0000 Subject: Allow meminfo metric values that are followed by a newline. Fixes #8. --- meminfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'meminfo.c') diff --git a/meminfo.c b/meminfo.c index 9ee1712..407b946 100644 --- a/meminfo.c +++ b/meminfo.c @@ -74,7 +74,7 @@ static void meminfo_collect(scrape_req *req, void *ctx) { do p++; while (*p == ' '); double value = strtod(p, &p); - if (*p != '\0' && *p != ' ') + if (*p != '\0' && *p != '\n' && *p != ' ') continue; if (*p == ' ') { -- cgit 1.4.1