git://git.onelab.eu
/
sfa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2fccb34
)
fix value error
author
Tony Mack
<tmack@paris.CS.Princeton.EDU>
Wed, 24 Oct 2012 02:36:29 +0000
(22:36 -0400)
committer
Tony Mack
<tmack@paris.CS.Princeton.EDU>
Wed, 24 Oct 2012 02:36:29 +0000
(22:36 -0400)
sfa/planetlab/plslices.py
patch
|
blob
|
history
diff --git
a/sfa/planetlab/plslices.py
b/sfa/planetlab/plslices.py
index
30cb539
..
be38155
100644
(file)
--- a/
sfa/planetlab/plslices.py
+++ b/
sfa/planetlab/plslices.py
@@
-246,7
+246,11
@@
class PlSlices:
for link in requested_links:
# get the ip address of the first node in the link
ifname1 = Xrn(link['interface1']['component_id']).get_leaf()
- (node_raw, device) = ifname1.split(':')
+ ifname_parts = ifname1.split(':')
+ node_raw = ifname_parts[0]
+ device = None
+ if len(ifname_parts) > 1:
+ device = ifname_parts[1]
node_id = int(node_raw.replace('node', ''))
node = nodes_dict[node_id]
if1 = interfaces_dict[node['interface_ids'][0]]