diff options
-rw-r--r-- | ryu/services/protocols/bgp/core_managers/table_manager.py | 3 | ||||
-rw-r--r-- | ryu/services/protocols/bgp/operator/internal_api.py | 2 | ||||
-rw-r--r-- | ryu/services/protocols/bgp/peer.py | 2 |
3 files changed, 3 insertions, 4 deletions
diff --git a/ryu/services/protocols/bgp/core_managers/table_manager.py b/ryu/services/protocols/bgp/core_managers/table_manager.py index a701644f..2ec0d80b 100644 --- a/ryu/services/protocols/bgp/core_managers/table_manager.py +++ b/ryu/services/protocols/bgp/core_managers/table_manager.py @@ -20,7 +20,6 @@ from ryu.lib.packet.bgp import RF_IPv6_UC from ryu.lib.packet.bgp import RF_IPv4_VPN from ryu.lib.packet.bgp import RF_IPv6_VPN from ryu.lib.packet.bgp import RF_RTC_UC -from ryu.lib.packet.bgp import BGPPathAttributeNextHop from ryu.lib.packet.bgp import BGPPathAttributeOrigin from ryu.lib.packet.bgp import BGPPathAttributeAsPath from ryu.lib.packet.bgp import BGP_ATTR_TYPE_ORIGIN @@ -489,7 +488,7 @@ class TableCoreManager(object): src_ver_num = 1 peer = None # set mandatory path attributes - nexthop = BGPPathAttributeNextHop("0.0.0.0") + nexthop = '0.0.0.0' origin = BGPPathAttributeOrigin(BGP_ATTR_ORIGIN_IGP) aspath = BGPPathAttributeAsPath([[]]) diff --git a/ryu/services/protocols/bgp/operator/internal_api.py b/ryu/services/protocols/bgp/operator/internal_api.py index c3a420e2..d23bdea5 100644 --- a/ryu/services/protocols/bgp/operator/internal_api.py +++ b/ryu/services/protocols/bgp/operator/internal_api.py @@ -119,7 +119,7 @@ class InternalApi(object): elif origin == BGP_ATTR_ORIGIN_EGP: origin = 'e' - nexthop = path.nexthop.value + nexthop = path.nexthop # Get the MED path attribute med = path.get_pattr(BGP_ATTR_TYPE_MULTI_EXIT_DISC) med = med.value if med else '' diff --git a/ryu/services/protocols/bgp/peer.py b/ryu/services/protocols/bgp/peer.py index 0779206f..ab14e5a9 100644 --- a/ryu/services/protocols/bgp/peer.py +++ b/ryu/services/protocols/bgp/peer.py @@ -1128,7 +1128,7 @@ class Peer(Source, Sink, NeighborConfListener, Activity): ' UPDATE. %s' % update_msg) return - next_hop = update_msg.get_path_attr(BGP_ATTR_TYPE_NEXT_HOP) + next_hop = update_msg.get_path_attr(BGP_ATTR_TYPE_NEXT_HOP).value # Nothing to do if we do not have any new NLRIs in this message. msg_nlri_list = update_msg.nlri if not msg_nlri_list: |