Module: check_mk
Branch: master
Commit: db0ab99e6fb1348f67a82624d00cc80dda722a69
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=db0ab99e6fb134…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Thu Sep 22 08:37:24 2016 +0200
Fixed path variables used in checks/inventory plugins
---
checks/logwatch | 2 +-
inventory/export_software_csv | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/checks/logwatch b/checks/logwatch
index 21f66a7..30e0958 100644
--- a/checks/logwatch
+++ b/checks/logwatch
@@ -238,7 +238,7 @@ def logwatch_parse_line(line):
# ignored.
def check_logwatch(item, params, info):
def cachefile_path(node):
- return tcp_cache_dir + "/" + node
+ return cmk.paths.tcp_cache_dir + "/" + node
now = time.time()
last_run = get_item_state("logwatch_last_run_%s" % item, 0)
diff --git a/inventory/export_software_csv b/inventory/export_software_csv
index ac04b6c..a80f04e 100644
--- a/inventory/export_software_csv
+++ b/inventory/export_software_csv
@@ -43,7 +43,7 @@ def inv_export_software_csv(hostname, params, tree):
filename = params["filename"].replace("<HOST>", hostname)
if not filename.startswith("/"):
- filename = var_dir + "/" + filename
+ filename = cmk.paths.var_dir + "/" + filename
dirname = filename.rsplit("/", 1)[0]
if not os.path.exists(dirname):
try: