aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve McIntyre <steve.mcintyre@linaro.org>2015-09-04 14:35:38 +0100
committerSteve McIntyre <steve.mcintyre@linaro.org>2015-09-04 14:35:38 +0100
commit8f27ae121691db1b38719eb948c26762c942ad77 (patch)
tree6667fab41d90f1fd8a81213ded42d056dd51a292
parent1ce09f9821e6647ab55d88f9d328725d288cd8f2 (diff)
Log when creating a VLAN failed, displaying the switch's error
Change-Id: Ia2af415eaf5146d81f5b7158af2db3bd68b0ffd1
-rw-r--r--util.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/util.py b/util.py
index 6bbbd5e..ce41f0c 100644
--- a/util.py
+++ b/util.py
@@ -280,7 +280,8 @@ class VlanUtil:
s.switch_disconnect()
del s
- except IOError:
+ except IOError as e:
+ logging.error('Failed to add VLAN %d to switch ID %d (%s): %s', tag, switch.switch_id, switch.name)
raise
except IOError: