Signed-off-by: YAMAMOTO Takashi <[email protected]>
---
 ryu/ofproto/oxm_fields.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ryu/ofproto/oxm_fields.py b/ryu/ofproto/oxm_fields.py
index 2e58386..6c1565a 100644
--- a/ryu/ofproto/oxm_fields.py
+++ b/ryu/ofproto/oxm_fields.py
@@ -222,7 +222,7 @@ def parse(mod, buf, offset):
     hdr_len = struct.calcsize(hdr_pack_str)
     oxm_type = header >> 9  # class|field
     oxm_hasmask = mod.oxm_tlv_header_extract_hasmask(header)
-    len = mod.oxm_tlv_header_extract_length(header)
+    oxm_len = mod.oxm_tlv_header_extract_length(header)
     oxm_class = oxm_type >> 7
     if oxm_class == OFPXMC_EXPERIMENTER:
         exp_hdr_pack_str = '!I'  # experimenter_id
@@ -243,7 +243,7 @@ def parse(mod, buf, offset):
         num = oxm_type
         exp_hdr_len = 0
     value_offset = offset + hdr_len + exp_hdr_len
-    value_len = len - exp_hdr_len
+    value_len = oxm_len - exp_hdr_len
     value_pack_str = '!%ds' % value_len
     assert struct.calcsize(value_pack_str) == value_len
     (value, ) = struct.unpack_from(value_pack_str, buf, value_offset)
-- 
1.9.4


------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to