Signed-off-by: FUJITA Tomonori <[email protected]>
---
ryu/lib/packet/bgp.py | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/ryu/lib/packet/bgp.py b/ryu/lib/packet/bgp.py
index adeda92..ad08d9e 100644
--- a/ryu/lib/packet/bgp.py
+++ b/ryu/lib/packet/bgp.py
@@ -1722,14 +1722,14 @@ class BGPPathAttributeClusterList(_PathAttribute):
def serialize_value(self):
buf = bytearray()
+ offset = 0
for cluster_id in self.value:
- cluster_id_bin = bytearray()
msg_pack_into(
self._VALUE_PACK_STR,
- cluster_id_bin,
- 0,
+ buf,
+ offset,
addrconv.ipv4.text_to_bin(cluster_id))
- buf += cluster_id_bin
+ offset += struct.calcsize(self._VALUE_PACK_STR)
return buf
--
1.8.5.2 (Apple Git-48)
------------------------------------------------------------------------------
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel