aboutsummaryrefslogtreecommitdiff
path: root/src/varnish_mib.mib2c
diff options
context:
space:
mode:
Diffstat (limited to 'src/varnish_mib.mib2c')
-rw-r--r--src/varnish_mib.mib2c14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/varnish_mib.mib2c b/src/varnish_mib.mib2c
index ae344be..a5367e0 100644
--- a/src/varnish_mib.mib2c
+++ b/src/varnish_mib.mib2c
@@ -1,5 +1,5 @@
# This file is part of varnish-mib -*- c -*-
-# Copyright (C) 2014 Sergey Poznyakoff
+# Copyright (C) 2014-2015 Sergey Poznyakoff
#
# Varnish-mib is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -198,9 +198,6 @@ void
varnish_snmp_init(void)
{
vd = VSM_New();
-
- if (VSM_Open(vd))
- exit(1);
}
void
@@ -240,12 +237,9 @@ handle_$i(netsnmp_mib_handler *handler,
@startperl@
&{$vars{'varnish_translate'}}($vars{'i'});
@endperl@
-
- if (VSM_Abandoned(vd)) {
- DEBUGMSGTL(("$modulename", "reopening vd\n"));
- VSM_Close(vd);
- VSM_Open(vd);
- }
+
+ if (!varnish_get_vsm_data())
+ return SNMP_ERR_NOSUCHNAME;
switch(reqinfo->mode) {
case MODE_GET:

Return to:

Send suggestions and report system problems to the System administrator.