Module: check_mk
Branch: master
Commit: d20b994388612853851c5a3ccdfb7823401de3c5
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=d20b9943886128…
Author: Moritz Kiemer <mo(a)mathias-kettner.de>
Date: Thu Sep 20 14:58:41 2018 +0200
dump_host.py: Fix TypeError if host has no IP address
Change-Id: Idaf30d59fe746fcb37ace08f0604c6b99724850f
---
cmk_base/dump_host.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cmk_base/dump_host.py b/cmk_base/dump_host.py
index 6cbc7a6..e2c4257 100644
--- a/cmk_base/dump_host.py
+++ b/cmk_base/dump_host.py
@@ -66,7 +66,7 @@ def dump_host(hostname):
else:
addresses += " (Primary: IPv4)"
- console.output(tty.yellow + "Addresses: " + tty.normal +
addresses + "\n")
+ console.output(tty.yellow + "Addresses: " + tty.normal +
(addresses if addresses is not None else "No IP") + "\n")
tags = config.tags_of_host(hostname)
console.output(tty.yellow + "Tags: " + tty.normal +
", ".join(tags) + "\n")