aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sos/plugins/infiniband.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sos/plugins/infiniband.py b/sos/plugins/infiniband.py
index d85194b4..5b2864d8 100644
--- a/sos/plugins/infiniband.py
+++ b/sos/plugins/infiniband.py
@@ -45,7 +45,7 @@ class Infiniband(Plugin, RedHatPlugin, DebianPlugin, UbuntuPlugin):
"perfquery"
]
IB_SYS_DIR = "/sys/class/infiniband/"
- ibs = os.listdir(IB_SYS_DIR)
+ ibs = os.listdir(IB_SYS_DIR) if os.path.isdir(IB_SYS_DIR) else []
for ib in ibs:
"""
Skip OPA hardware, as infiniband-diags tools does not understand