mirror of
https://github.com/faucetsdn/ryu.git
synced 2026-05-08 13:56:09 +02:00
of1.3: fix OFPMeterStats
len -> length as the latter seems to be expected by OFPMultipartReply.parser_stats_body. Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
This commit is contained in:
parent
e943f61068
commit
c519c7d86f
@ -2447,7 +2447,7 @@ class OFPMeterStats(object):
|
||||
def __init__(self):
|
||||
super(OFPMeterStats, self).__init__()
|
||||
self.meter_id = None
|
||||
self.len = None
|
||||
self.length = None
|
||||
self.flow_count = None
|
||||
self.packet_in_count = None
|
||||
self.byte_in_count = None
|
||||
@ -2459,7 +2459,7 @@ class OFPMeterStats(object):
|
||||
def parser(cls, buf, offset):
|
||||
meter_stats = cls()
|
||||
|
||||
(meter_stats.meter_id, meter_stats.len,
|
||||
(meter_stats.meter_id, meter_stats.length,
|
||||
meter_stats.flow_count, meter_stats.packet_in_count,
|
||||
meter_stats.byte_in_count, meter_stats.duration_sec,
|
||||
meter_stats.duration_nsec) = struct.unpack_from(
|
||||
@ -2468,7 +2468,7 @@ class OFPMeterStats(object):
|
||||
|
||||
meter_stats.band_stats = []
|
||||
length = ofproto_v1_3.OFP_METER_STATS_SIZE
|
||||
while length < meter_stats.len:
|
||||
while length < meter_stats.length:
|
||||
band_stats = OFPMeterBandStats.parser(buf, offset)
|
||||
meter_stats.band_stats.append(band_stats)
|
||||
offset += ofproto_v1_3.OFP_METER_BAND_STATS_SIZE
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user