From: Jonathan Huot Date: Thu, 2 Aug 2012 15:56:05 +0000 (+0300) Subject: Added the instance name to varnish API X-Git-Tag: collectd-5.1.1~12 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=b736009816ddeb00a2ec4c7e3986f98522215afd;p=collectd.git Added the instance name to varnish API Fixed issue collectd#110 Signed-off-by: Florian Forster --- diff --git a/src/varnish.c b/src/varnish.c index 357b5f11..de60e39c 100644 --- a/src/varnish.c +++ b/src/varnish.c @@ -412,6 +412,11 @@ static int varnish_read (user_data_t *ud) /* {{{ */ vd = VSM_New(); VSC_Setup(vd); + if (VSM_n_Arg(vd, conf->instance) == -1) + { + ERROR ("Varnish plugin : unable to load statistics from instance"); + return (-1); + } if (VSC_Open (vd, /* diag = */ 1)) { ERROR ("varnish plugin: Unable to load statistics.");