summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorYAMAMOTO Takashi <yamamoto@valinux.co.jp>2013-09-02 15:06:15 +0900
committerFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2013-09-02 19:41:38 +0900
commit1bf4f6ddd3291fca8bae242b008672b0cef6f674 (patch)
tree312deedccbc924d6473268a796e1892f03673709
parentd388d994c9a2499541d0d6fe6d3f583a342f3abe (diff)
of13: make OFPPacketOut.actions_len visible to users
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
-rw-r--r--ryu/ofproto/ofproto_v1_3_parser.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/ryu/ofproto/ofproto_v1_3_parser.py b/ryu/ofproto/ofproto_v1_3_parser.py
index 0d8aee56..88b1e67e 100644
--- a/ryu/ofproto/ofproto_v1_3_parser.py
+++ b/ryu/ofproto/ofproto_v1_3_parser.py
@@ -2218,23 +2218,23 @@ class OFPPacketOut(MsgBase):
datapath.send_msg(req)
"""
def __init__(self, datapath, buffer_id=None, in_port=None, actions=None,
- data=None):
+ data=None, actions_len=None):
assert in_port is not None
super(OFPPacketOut, self).__init__(datapath)
self.buffer_id = buffer_id
self.in_port = in_port
- self._actions_len = 0
+ self.actions_len = 0
self.actions = actions
self.data = data
def _serialize_body(self):
- self._actions_len = 0
+ self.actions_len = 0
offset = ofproto_v1_3.OFP_PACKET_OUT_SIZE
for a in self.actions:
a.serialize(self.buf, offset)
offset += a.len
- self._actions_len += a.len
+ self.actions_len += a.len
if self.data is not None:
assert self.buffer_id == 0xffffffff
@@ -2242,7 +2242,7 @@ class OFPPacketOut(MsgBase):
msg_pack_into(ofproto_v1_3.OFP_PACKET_OUT_PACK_STR,
self.buf, ofproto_v1_3.OFP_HEADER_SIZE,
- self.buffer_id, self.in_port, self._actions_len)
+ self.buffer_id, self.in_port, self.actions_len)
@_set_msg_type(ofproto_v1_3.OFPT_FLOW_MOD)