projects
/
osm
/
vim-emu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
migration to python3 (#1)
[osm/vim-emu.git]
/
src
/
emuvim
/
api
/
openstack
/
resources
/
net.py
diff --git
a/src/emuvim/api/openstack/resources/net.py
b/src/emuvim/api/openstack/resources/net.py
index
112cca6
..
42af151
100755
(executable)
--- a/
src/emuvim/api/openstack/resources/net.py
+++ b/
src/emuvim/api/openstack/resources/net.py
@@
-24,6
+24,7
@@
# acknowledge the contributions of their colleagues of the SONATA
# partner consortium (www.sonata-nfv.eu).
import re
# acknowledge the contributions of their colleagues of the SONATA
# partner consortium (www.sonata-nfv.eu).
import re
+from json import dumps
class Net:
class Net:
@@
-243,7
+244,7
@@
class Net:
:return: IP address as int.
:rtype: ``int``
"""
:return: IP address as int.
:rtype: ``int``
"""
- o =
map(int, ip.split('.'
))
+ o =
list(map(int, ip.split('.')
))
res = (16777216 * o[0]) + (65536 * o[1]) + (256 * o[2]) + o[3]
return res
res = (16777216 * o[0]) + (65536 * o[1]) + (256 * o[2]) + o[3]
return res
@@
-340,4
+341,4
@@
class Net:
self.gateway_ip,
self.segmentation_id,
self._cidr,
self.gateway_ip,
self.segmentation_id,
self._cidr,
-
self.start_end_dict
))
+
dumps(self.start_end_dict)
))