Code Review
/
vpp.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
VPP-1440: clean up coverity warnings
[vpp.git]
/
test
/
vpp_gre_interface.py
diff --git
a/test/vpp_gre_interface.py
b/test/vpp_gre_interface.py
index
91293c3
..
d5a40ee
100644
(file)
--- a/
test/vpp_gre_interface.py
+++ b/
test/vpp_gre_interface.py
@@
-11,9
+11,7
@@
class VppGreInterface(VppInterface):
def __init__(self, test, src_ip, dst_ip, outer_fib_id=0, type=0,
session=0):
""" Create VPP GRE interface """
def __init__(self, test, src_ip, dst_ip, outer_fib_id=0, type=0,
session=0):
""" Create VPP GRE interface """
- self._sw_if_index = 0
super(VppGreInterface, self).__init__(test)
super(VppGreInterface, self).__init__(test)
- self._test = test
self.t_src = src_ip
self.t_dst = dst_ip
self.t_outer_fib = outer_fib_id
self.t_src = src_ip
self.t_dst = dst_ip
self.t_outer_fib = outer_fib_id
@@
-27,9
+25,9
@@
class VppGreInterface(VppInterface):
outer_fib_id=self.t_outer_fib,
tunnel_type=self.t_type,
session_id=self.t_session)
outer_fib_id=self.t_outer_fib,
tunnel_type=self.t_type,
session_id=self.t_session)
- self.
_sw_if_index = r.sw_if_index
+ self.
set_sw_if_index(r.sw_if_index)
self.generate_remote_hosts()
self.generate_remote_hosts()
- self.
_test.registry.register(self, self._
test.logger)
+ self.
test.registry.register(self, self.
test.logger)
def remove_vpp_config(self):
s = socket.inet_pton(socket.AF_INET, self.t_src)
def remove_vpp_config(self):
s = socket.inet_pton(socket.AF_INET, self.t_src)
@@
-45,7
+43,7
@@
class VppGreInterface(VppInterface):
return self.object_id()
def object_id(self):
return self.object_id()
def object_id(self):
- return "gre-%d" % self.
_
sw_if_index
+ return "gre-%d" % self.sw_if_index
class VppGre6Interface(VppInterface):
class VppGre6Interface(VppInterface):
@@
-56,9
+54,7
@@
class VppGre6Interface(VppInterface):
def __init__(self, test, src_ip, dst_ip, outer_fib_id=0, type=0,
session=0):
""" Create VPP GRE interface """
def __init__(self, test, src_ip, dst_ip, outer_fib_id=0, type=0,
session=0):
""" Create VPP GRE interface """
- self._sw_if_index = 0
super(VppGre6Interface, self).__init__(test)
super(VppGre6Interface, self).__init__(test)
- self._test = test
self.t_src = src_ip
self.t_dst = dst_ip
self.t_outer_fib = outer_fib_id
self.t_src = src_ip
self.t_dst = dst_ip
self.t_outer_fib = outer_fib_id
@@
-73,9
+69,9
@@
class VppGre6Interface(VppInterface):
tunnel_type=self.t_type,
session_id=self.t_session,
is_ip6=1)
tunnel_type=self.t_type,
session_id=self.t_session,
is_ip6=1)
- self.
_sw_if_index = r.sw_if_index
+ self.
set_sw_if_index(r.sw_if_index)
self.generate_remote_hosts()
self.generate_remote_hosts()
- self.
_test.registry.register(self, self._
test.logger)
+ self.
test.registry.register(self, self.
test.logger)
def remove_vpp_config(self):
s = socket.inet_pton(socket.AF_INET6, self.t_src)
def remove_vpp_config(self):
s = socket.inet_pton(socket.AF_INET6, self.t_src)