diff options
author | Paul Jakma <paul@quagga.net> | 2011-03-20 22:08:02 +0000 |
---|---|---|
committer | Paul Jakma <paul@quagga.net> | 2011-03-20 22:09:15 +0000 |
commit | d1de1c25962b5470f3825bc82d15e4dd29e1f842 (patch) | |
tree | 9e9b3c6ed51a0fdc78e0eb8900fad8f7e7598b98 /bgpd | |
parent | 4dd87df5af8a59174362e44f83df11f12457c8b4 (diff) | |
parent | e6844aa5d23cf56dd1f31afc96e8145ab188953f (diff) |
Merge paul/ospfd/201012-review ospfd and lib/ fixes and performance improvements
Diffstat (limited to 'bgpd')
-rw-r--r-- | bgpd/bgp_debug.c | 7 | ||||
-rw-r--r-- | bgpd/bgp_dump.c | 4 | ||||
-rw-r--r-- | bgpd/bgp_packet.c | 6 | ||||
-rw-r--r-- | bgpd/bgp_route.c | 9 | ||||
-rw-r--r-- | bgpd/bgp_vty.c | 6 |
5 files changed, 18 insertions, 14 deletions
diff --git a/bgpd/bgp_debug.c b/bgpd/bgp_debug.c index c2077a59..26b35dfc 100644 --- a/bgpd/bgp_debug.c +++ b/bgpd/bgp_debug.c @@ -331,7 +331,6 @@ ALIAS (no_debug_bgp_as4, undebug_bgp_as4_cmd, "undebug bgp as4", UNDEBUG_STR - DEBUG_STR BGP_STR "BGP AS4 actions\n") @@ -340,6 +339,7 @@ DEFUN (debug_bgp_as4_segment, "debug bgp as4 segment", DEBUG_STR BGP_STR + "BGP AS4 actions\n" "BGP AS4 aspath segment handling\n") { if (vty->node == CONFIG_NODE) @@ -358,6 +358,7 @@ DEFUN (no_debug_bgp_as4_segment, NO_STR DEBUG_STR BGP_STR + "BGP AS4 actions\n" "BGP AS4 aspath segment handling\n") { if (vty->node == CONFIG_NODE) @@ -374,8 +375,8 @@ ALIAS (no_debug_bgp_as4_segment, undebug_bgp_as4_segment_cmd, "undebug bgp as4 segment", UNDEBUG_STR - DEBUG_STR BGP_STR + "BGP AS4 actions\n" "BGP AS4 aspath segment handling\n") DEFUN (debug_bgp_fsm, @@ -417,7 +418,6 @@ ALIAS (no_debug_bgp_fsm, undebug_bgp_fsm_cmd, "undebug bgp fsm", UNDEBUG_STR - DEBUG_STR BGP_STR "Finite State Machine\n") @@ -715,7 +715,6 @@ ALIAS (no_debug_bgp_zebra, undebug_bgp_zebra_cmd, "undebug bgp zebra", UNDEBUG_STR - DEBUG_STR BGP_STR "BGP Zebra messages\n") diff --git a/bgpd/bgp_dump.c b/bgpd/bgp_dump.c index 8087a403..edb725a9 100644 --- a/bgpd/bgp_dump.c +++ b/bgpd/bgp_dump.c @@ -356,7 +356,11 @@ bgp_dump_routes_func (int afi, int first_run, unsigned int seq) stream_putw(obuf, info->peer->table_dump_index); /* Originated */ +#ifdef HAVE_CLOCK_MONOTONIC + stream_putl (obuf, time(NULL) - (bgp_clock() - info->uptime)); +#else stream_putl (obuf, info->uptime); +#endif /* HAVE_CLOCK_MONOTONIC */ /* Dump attribute. */ /* Skip prefix & AFI/SAFI for MP_NLRI */ diff --git a/bgpd/bgp_packet.c b/bgpd/bgp_packet.c index a5f9552c..9102add7 100644 --- a/bgpd/bgp_packet.c +++ b/bgpd/bgp_packet.c @@ -1885,12 +1885,6 @@ bgp_notify_receive (struct peer *peer, bgp_size_t size) bgp_notify.subcode == BGP_NOTIFY_OPEN_UNSUP_PARAM ) UNSET_FLAG (peer->sflags, PEER_STATUS_CAPABILITY_OPEN); - /* Also apply to Unsupported Capability until remote router support - capability. */ - if (bgp_notify.code == BGP_NOTIFY_OPEN_ERR && - bgp_notify.subcode == BGP_NOTIFY_OPEN_UNSUP_CAPBL) - UNSET_FLAG (peer->sflags, PEER_STATUS_CAPABILITY_OPEN); - BGP_EVENT_ADD (peer, Receive_NOTIFICATION_message); } diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index df23dda3..60e9610e 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -5978,6 +5978,9 @@ route_vty_out_detail (struct vty *vty, struct bgp *bgp, struct prefix *p, char buf1[BUFSIZ]; struct attr *attr; int sockunion_vty_out (struct vty *, union sockunion *); +#ifdef HAVE_CLOCK_MONOTONIC + time_t tbuf; +#endif attr = binfo->attr; @@ -6144,8 +6147,12 @@ route_vty_out_detail (struct vty *vty, struct bgp *bgp, struct prefix *p, bgp_damp_info_vty (vty, binfo); /* Line 7 display Uptime */ - time_t tbuf = time(NULL) - (bgp_clock() - binfo->uptime); +#ifdef HAVE_CLOCK_MONOTONIC + tbuf = time(NULL) - (bgp_clock() - binfo->uptime); vty_out (vty, " Last update: %s", ctime(&tbuf)); +#else + vty_out (vty, " Last update: %s", ctime(&binfo->uptime)); +#endif /* HAVE_CLOCK_MONOTONIC */ } vty_out (vty, "%s", VTY_NEWLINE); } diff --git a/bgpd/bgp_vty.c b/bgpd/bgp_vty.c index 88be52e2..ec0106a8 100644 --- a/bgpd/bgp_vty.c +++ b/bgpd/bgp_vty.c @@ -9952,7 +9952,7 @@ community_list_perror (struct vty *vty, int ret) switch (ret) { case COMMUNITY_LIST_ERR_CANT_FIND_LIST: - vty_out (vty, "%% Can't find communit-list%s", VTY_NEWLINE); + vty_out (vty, "%% Can't find community-list%s", VTY_NEWLINE); break; case COMMUNITY_LIST_ERR_MALFORMED_VAL: vty_out (vty, "%% Malformed community-list value%s", VTY_NEWLINE); @@ -10313,7 +10313,7 @@ DEFUN (show_ip_community_list_arg, list = community_list_lookup (bgp_clist, argv[0], COMMUNITY_LIST_MASTER); if (! list) { - vty_out (vty, "%% Can't find communit-list%s", VTY_NEWLINE); + vty_out (vty, "%% Can't find community-list%s", VTY_NEWLINE); return CMD_WARNING; } @@ -10663,7 +10663,7 @@ DEFUN (show_ip_extcommunity_list_arg, list = community_list_lookup (bgp_clist, argv[0], EXTCOMMUNITY_LIST_MASTER); if (! list) { - vty_out (vty, "%% Can't find extcommunit-list%s", VTY_NEWLINE); + vty_out (vty, "%% Can't find extcommunity-list%s", VTY_NEWLINE); return CMD_WARNING; } |