From 197a6c49a68f55b445b4c31316eb022e30fee300 Mon Sep 17 00:00:00 2001 From: IWASE Yusuke Date: Tue, 22 Nov 2016 11:20:19 +0900 Subject: packet/bgp: Support multiple BGP messages in a packet This patch fixes to BGPMessage.parser() to return the reference to its own class and to support multiple BGP messages in a single packet. Signed-off-by: IWASE Yusuke Signed-off-by: FUJITA Tomonori --- ryu/lib/packet/bgp.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ryu/lib/packet/bgp.py b/ryu/lib/packet/bgp.py index 38787965..bec13b7f 100644 --- a/ryu/lib/packet/bgp.py +++ b/ryu/lib/packet/bgp.py @@ -3600,7 +3600,7 @@ class BGPMessage(packet_base.PacketBase, _TypeDisp): subcls = cls._lookup_type(type_) kwargs = subcls.parser(binmsg) return subcls(marker=marker, len_=len_, type_=type_, - **kwargs), None, rest + **kwargs), cls, rest def serialize(self, payload=None, prev=None): # fixup -- cgit v1.2.3