Age | Commit message (Collapse) | Author |
|
2006-02-05 Paul Jakma <paul.jakma@sun.com>
* bgp_route.h: Add BGP_INFO_COUNTED to track whether
prefix has been counted or not.
* bgp_route.c: (bgp_pcount_{inc,dec}rement) new helpers, to
centralise inc/dec of prefix-count,
(bgp_rib_remove) Remove pcount decrement, use helper.
(bgp_rib_withdraw) ditto, additionally use previous function
too.
(bgp_update_main) Use pcount helpers.
(bgp_clear_route_node) ditto, aslo REMOVED routes don't need
clearing.
|
|
2006-02-02 Paul Jakma <paul.jakma@sun.com>
* workqueue.h: (struct work_queue) Remove the delay field.
It served no purpose and just introduced bad behaviour.
Should be excised before its allowed to escape into 1.0.
This removes need for the 'flood' and runs_since_clear
fields.
* workqueue.c: (general) excise delay factor between queue
runs, hence the 'flood' crap too.. See above.
* bgp_route.c: (bgp_{clear_node,process}_queue_init) delay
field is removed from workqueue spec.
|
|
2006-01-19 Paul Jakma <paul.jakma@sun.com>
* (general) various miscellaneous compiler warning fixes.
Remove redundant break statements from switch clauses
which return.
return from main, not exit, cause it annoys SOS.
Remove stray semi-colons which cause empty-statement
warnings.
* zebra/main.c: (sighup) remove private declaration of external
function.
|
|
2006-01-17 Paul Jakma <paul.jakma@sun.com>
* bgp_nexthop.c: (zlookup_read*) convert to new Zserv format.
(zlookup_query_ipv6) ditto.
(bgp_import_check) ditto.
* isis_zebra.c: (isis_zebra_route_add_ipv4) fix for new
zserv format.
|
|
2006-01-16 Paul Jakma <paul.jakma@sun.com>
* bgp_aspath.c:
(aspath_snmp_pathseg) move the static stream pointer out to
file scope, so it can be freed.
(aspath_finish) new function, free aspath resources.
* bgp_aspath.h: (aspath_finish) export.
|
|
2006-01-16 Paul Jakma <paul.jakma@sun.com>
* bgp_aspath.c: (assegment_append_asns) XREALLOC can return
NULL theoretically, take care not to lose the allocated data.
(aspath_hash_alloc) aspath_dup already set the aspath
string - fix leak.
(aspath_parse) aspath_hash_alloc dupes the entire aspath,
including segments, but we forgot to free the temporary
assegment.
|
|
2006-01-10 Juris Kalnins <juris@mt.lv>
* bgpd.h: (bgp_router_id_unset) ex-function, remove.
|
|
2005-11-23 Paul Jakma <paul.jakma@sun.com>
* bgp_aspath.c: (assegments_parse) should be static
2005-11-23 Juergen Kammer <j.kammer@eurodata.de>
* bgp_aspath.c: (aspath_cmp_left_confed) fix SEGV for case
where one or both paths are empty.
|
|
* zebra_rib.c: (rib_process) convert to new workqueue specs and
shut up gcc, which complains about cast from void via
function parameters, for some dumb reason. Do the cast
inside the function instead.
(rib_queue_qnode_del) ditto.
(rib_queue_init) no need for the casts anymore.
|
|
* bgp_damp.c: (bgp_reuse_timer) struct bgp can be retrieved via
the struct bgp_damp_info, no need to guess by using
bgp_get_default().
|
|
* zebra.h: Declare new functions zebra_route_string() and
zebra_route_char().
* log.c: (zroute_lookup,zebra_route_string,zebra_route_char) New
functions to map zebra route numbers to strings.
* zebra_vty.c: (route_type_str) Remove obsolete function: use new
library function zebra_route_string() instead. Note that there
are a few differences: for IPv6 routes, we now get "ripng" and
"ospf6" instead of the old behavior ("rip" and "ospf").
(route_type_char) Remove obsolete function: ues new library function
zebra_route_char() instead. Note that there is one difference:
the old function returned 'S' for a ZEBRA_ROUTE_SYSTEM route,
whereas the new one returns 'X'.
(vty_show_ip_route_detail,vty_show_ipv6_route_detail) Replace
route_type_str() with zebra_route_string().
(vty_show_ip_route,vty_show_ipv6_route) Replace route_type_char()
with zebra_route_char().
* bgp_vty.c: (bgp_config_write_redistribute) Use new library function
zebra_route_string instead of a local hard-coded table.
* ospf6_asbr.c: Remove local hard-coded tables zroute_name and
zroute_abname. Change the ZROUTE_NAME macro to use new library
function zebra_route_string(). Remove the ZROUTE_ABNAME macro.
(ospf6_asbr_external_route_show): Replace ZROUTE_ABNAME() with
a call to zebra_route_char(), and be sure to fix the format string,
since we now have a char instead of a char *.
* ospf6_zebra.c: Remove local hard-coded tables zebra_route_name and
zebra_route_abname. Note that the zebra_route_name[] table
contained mixed-case strings, whereas the zebra_route_string()
function returns lower-case strings.
(ospf6_zebra_read_ipv6): Change debug message to use new library
function zebra_route_string() instead of zebra_route_name[].
(show_zebra): Use new library function zebra_route_string() instead
of zebra_route_name[].
* ospf_dump.c: Remove local hard-coded table ospf_redistributed_proto.
(ospf_redist_string) New function implemented using new library
function zebra_route_string(). Note that there are a few differences
in the output that will result: the new function returns strings
that are lower-case, whereas the old table was mixed case. Also,
the old table mapped ZEBRA_ROUTE_OSPF6 to "OSPFv3", whereas the
new function returns "ospf6".
* ospfd.h: Remove extern struct message ospf_redistributed_proto[],
and add extern const char *ospf_redist_string(u_int route_type)
instead.
* ospf_asbr.c: (ospf_external_info_add) In two messages, use
ospf_redist_string instead of LOOKUP(ospf_redistributed_proto).
* ospf_vty.c: Remove local hard-coded table distribute_str.
(config_write_ospf_redistribute,config_write_ospf_distribute): Use
new library function zebra_route_string() instead of distribute_str[].
* ospf_zebra.c: (ospf_redistribute_set,ospf_redistribute_unset,
ospf_redistribute_default_set,ospf_redistribute_check)
In debug messages, use ospf_redist_string() instead of
LOOKUP(ospf_redistributed_proto).
* rip_zebra.c: (config_write_rip_redistribute): Remove local hard-coded
table str[]. Replace str[] with calls to new library function
zebra_route_string().
* ripd.c: Remove local hard-coded table route_info[].
(show_ip_rip) Replace uses of str[] with calls to new library
functions zebra_route_char and zebra_route_string.
* ripng_zebra.c: (ripng_redistribute_write) Remove local hard-coded
table str[]. Replace str[i] with new library function
zebra_route_string(i).
* ripngd.c: Remove local hard-coded table route_info[].
(show_ipv6_ripng) Use new library function zebra_route_char() instead
of table route_info[].
|
|
* bgp_packet.c: fix compilation when DEBUG is used.
|
|
* Makefile.am: bgpd shouldn't list libgp's sources as its own.
Use LDADD.
* bgp_aspath.h:
(struct assegment) New struct, abstract representation of a
list of AS_PATH segments and the contained ASNs.
(struct aspath) Remove the raw-data related
fields, reference the abstract struct assegment instead.
Remove several other computed fields, it's just a
headache to maintain them and they're cheap to compute from
struct assegment.
(aspath_parse) parse a stream, not a pointer to raw data.
(aspath_count_{hops,confeds,size}) helpers to access
information formerly directly contained in struct aspath.
(aspath_snmp_pathseg) Helper for SNMP, BGP MIB wants
to be able to output hex representation of raw data.
* bgp_aspath.c: (general) partial-rewrite. Store aspath data
as an abstract singly-linked list of abstract segments,
rather than storing the raw data, and parsing it each and
every time. Remove several count/size fields which are cheap
to compute from the abstract segment structure.
(global) Include stream.h, needed for aspath_parse, and
others. Couple of helper macros added.
(struct assegment_header) Just the header, and only the
header.
(assegment_data_{new,free}) convenience functions for
AS_SEG_DATA allocation, the dynamic, per-segment array of
ASNs.
(assegment_{new,free,free_all,dup,dup_all}) convenience
functions for creating struct assegments. The _all forms will
follow the entire chain of segments from the given segment.
(assegment_prepend_asns) new function, prepend an ASN N times
to segment.
(assegment_append_asns) Append a list (array) of ASNs to
segment.
(int_cmp) convenience function for the aspath hash.
(assegment_normalise) new function. Normalise the given
segment chain to meet expectations of Quagga, and to
eliminate differing raw representations of the same paths.
Merge 'runs' of SEQUENCEs into one segment as our internal
segment is not limited by the protocol AS_PATH segment
length. Sort ASNs in SETs.
(aspath_new) Take void argument to quell warnings. Use the
assegment convenience functions.
(assegment_count_{asns,confeds,hops}) new functions to
compute at runtime values previously held in struct aspath.
(aspath_size) ditto.
(aspath_make_str_count) rewritten to stringify new
representation, and to be slightly easier to understand
hopefully.
(aspath_str_update) convenience function, update the aspath
str. Should investigate removing maintained string from
struct aspath, just run-time compute it, as per other fields.
It's just a maintenance headache, would save noticeable
amount of RAM with possibly not much extra run-time cost.
(aspath_dup) use the assegment dup functions.
(aspath_hash_alloc) Take void * argument to satisfy gcc. Use
the proper helper functions to dup data.
(assegments_parse) new function. parse raw AS_PATH data into
struct assegments. Normalise and return the head of the list.
(aspath_parse) Parse a stream, not pointer to raw data and
use assegments_parse to do it.
(assegment_data_put) Write out a single segment data in protocol
form to stream.
(assegment_header_put) ditto but for segment header.
(aspath_put) new function. As per previous but for an entire
struct aspath.
(aspath_snmp_pathseg) wrapper around aspath_put for
bgp_snmp.c. Uses a static buffer sadly.
(aspath_aggregate_as_set_add) rewritten to use assegments.
(aspath_aggregate) ditto
(aspath_{firstas,loop,private_as}_check) ditto
(aspath_{merge,prepend,add_one_as}) ditto
(aspath_cmp_left{_confed}) ditto
(aspath_delete_confed_seq) ditto, plus fixed to properly
delete all leading confed segments.
(aspath_as_add) Just use assegment_append_asns.
(aspath_segment_add) updated to use assegments.
(enum as_token) Add values for confeds
(aspath_gettoken) Add support for confeds
(aspath_str2aspath) ditto
(aspath_key_make) updated to use as_segments. Also, add
segment type into the hash value as appropriate.
(aspath_cmp) updated to use as_segments.
(aspath_print) don't segfault on NULL argument.
* bgp_attr.c: (bgp_attr_aspath) aspath_parse wants the stream
now. No need for manual forwarding of stream.
(bgp_packet_attribute) empty aspath is now denoted by NULL
segment field, length is gone.
Use aspath_size() to determine size.
(bgp_attr_init) Fix declaration, explicitely specify void
arg.
(bgp_dump_routes_attr) Use aspath_size() to determine size.
* bgp_route.c: (bgp_info_cmp) use the aspath_count_* functions.
(bgp_rib_withdraw) remove unused variable. Use
aspath_count_hops.
* bgp_snmp.c: (bgp4PathAttrTable) raw data is gone, use
aspath_snmp_pathseg to get the representation.
|
|
* bgp_vty.c: (bgp_vty_init) gcc 4 compile fix. static
function declarations shouldn't be inside functions.
* bgp_dump.c: (bgp_dump_interval_add) ditto.
|
|
introduced long time ago with route server patch. Hopefully
it's last case to fix - route-server client not in peer group.
[backport candidate]
|
|
* bgp_vty.c: (general) Add support for BGP IPv6 Multicast SAFI
commands and BGP_IPV6M_NODE.
|
|
* bgp_route.h: (struct bgp_info) add a new flag, BGP_INFO_REMOVED.
BGP_INFO_VALID is already overloaded, don't care to do same thing
to STALE or HISTORY.
* bgpd.h: (BGP_INFO_HOLDDOWN) Add INFO_REMOVED to the macro, as a
route which should generally be ignored.
* bgp_route.c: (bgp_info_delete) Just set the REMOVE flag, rather
than doing actual work, so that bgp_process (called directly,
or indirectly via the scanner) can catch withdrawn routes.
(bgp_info_reap) Actually remove the route, what bgp_info_delete
used to do, only for use by bgp_process.
(bgp_best_selection) reap any REMOVED routes, other than the old
selected route.
(bgp_process_rsclient) reap the old-selected route, if appropriate
(bgp_process_main) ditto
(bgp_rib_withdraw, bgp_rib_remove) make them more consistent with
each other. Don't play games with the VALID flag, bgp_process
is async now, so it didn't make a difference anyway.
Remove the 'force' argument from bgp_rib_withdraw, withdraw+force
is equivalent to bgp_rib_remove. Update all its callers.
(bgp_update_rsclient) bgp_rib_withdraw and force set is same as
bgp_rib_remove.
(route_vty_short_status_out) new helper to print the leading
route-status string used in many command outputs. Consolidate.
(route_vty_out, route_vty_out_tag, damp_route_vty_out,
flap_route_vty_out) use route_vty_short_status_out rather than
duplicate.
(route_vty_out_detail) print state of REMOVED flag.
(BGP_SHOW_SCODE_HEADER) update for Removed flag.
|
|
2005-05-27. While ecommunity fix seems to be correct, community case
isn't.
Fixes bugzilla #209.
[backport candidate]
|
|
* (global) The great bgpd extern and static'ification.
* bgp_routemap.c: remove unused ROUTE_MATCH_ASPATH_OLD code
(route_set_metric_compile) fix u_int32_t to ULONG_MAX comparison
warnings.
* bgp_route.h: (bgp_process, bgp_withdraw, bgp_update) export these
used by various files which had their own private declarations,
in the case of mplsvpn - incorrect.
|
|
* bgpd.c: (bgp_terminate) workqueue's are lazy allocated and its
possible to terminate bgpd before workqueues were setup, causing
an abort/crash. Reported by Ashish Mehta of Sun.
|
|
* bgpd/(general) refcount struct peer and bgp_info, hence allowing us
add work_queues for bgp_process.
* bgpd/bgp_route.h: (struct bgp_info) Add 'lock' field for refcount.
Add bgp_info_{lock,unlock} helper functions.
Add bgp_info_{add,delete} helpers, to remove need for
users managing locking/freeing of bgp_info and bgp_node's.
* bgpd/bgp_table.h: (struct bgp_node) Add a flags field, and
BGP_NODE_PROCESS_SCHEDULED to merge redundant processing of
nodes.
* bgpd/bgp_fsm.h: Make the ON/OFF/ADD/REMOVE macros lock and unlock
peer reference as appropriate.
* bgpd/bgp_damp.c: Remove its internal prototypes for
bgp_info_delete/free. Just use bgp_info_delete.
* bgpd/bgpd.h: (struct bgp_master) Add work_queue pointers.
(struct peer) Add reference count 'lock'
(peer_lock,peer_unlock) New helpers to take/release reference
on struct peer.
* bgpd/bgp_advertise.c: (general) Add peer and bgp_info refcounting
and balance how references are taken and released.
(bgp_advertise_free) release bgp_info reference, if appropriate
(bgp_adj_out_free) unlock peer
(bgp_advertise_clean) leave the adv references alone, or else
call bgp_advertise_free cant unlock them.
(bgp_adj_out_set) lock the peer on new adj's, leave the reference
alone otherwise. lock the new bgp_info reference.
(bgp_adj_in_set) lock the peer reference
(bgp_adj_in_remove) and unlock it here
(bgp_sync_delete) make hash_free on peer conditional, just in
case.
* bgpd/bgp_fsm.c: (general) document that the timers depend on
bgp_event to release a peer reference.
(bgp_fsm_change_status) moved up the file, unchanged.
(bgp_stop) Decrement peer lock as many times as cancel_event
canceled - shouldnt be needed but just in case.
stream_fifo_clean of obuf made conditional, just in case.
(bgp_event) always unlock the peer, regardless of return value
of bgp_fsm_change_status.
* bgpd/bgp_packet.c: (general) change several bgp_stop's to BGP_EVENT's.
(bgp_read) Add a mysterious extra peer_unlock for ACCEPT_PEERs
along with a comment on it.
* bgpd/bgp_route.c: (general) Add refcounting of bgp_info, cleanup
some of the resource management around bgp_info. Refcount peer.
Add workqueues for bgp_process and clear_table.
(bgp_info_new) make static
(bgp_info_free) Ditto, and unlock the peer reference.
(bgp_info_lock,bgp_info_unlock) new exported functions
(bgp_info_add) Add a bgp_info to a bgp_node in correct fashion,
taking care of reference counts.
(bgp_info_delete) do the opposite of bgp_info_add.
(bgp_process_rsclient) Converted into a work_queue work function.
(bgp_process_main) ditto.
(bgp_processq_del) process work queue item deconstructor
(bgp_process_queue_init) process work queue init
(bgp_process) call init function if required, set up queue item
and add to queue, rather than calling process functions directly.
(bgp_rib_remove) let bgp_info_delete manage bgp_info refcounts
(bgp_rib_withdraw) ditto
(bgp_update_rsclient) let bgp_info_add manage refcounts
(bgp_update_main) ditto
(bgp_clear_route_node) clear_node_queue work function, does
per-node aspects of what bgp_clear_route_table did previously
(bgp_clear_node_queue_del) clear_node_queue item delete function
(bgp_clear_node_complete) clear_node_queue completion function,
it unplugs the process queues, which have to be blocked while
clear_node_queue is being processed to prevent a race.
(bgp_clear_node_queue_init) init function for clear_node_queue
work queues
(bgp_clear_route_table) Sets up items onto a workqueue now, rather
than clearing each node directly. Plugs both process queues to
avoid potential race.
(bgp_static_withdraw_rsclient) let bgp_info_{add,delete} manage
bgp_info refcounts.
(bgp_static_update_rsclient) ditto
(bgp_static_update_main) ditto
(bgp_static_update_vpnv4) ditto, remove unneeded cast.
(bgp_static_withdraw) see bgp_static_withdraw_rsclient
(bgp_static_withdraw_vpnv4) ditto
(bgp_aggregate_{route,add,delete}) ditto
(bgp_redistribute_{add,delete,withdraw}) ditto
* bgpd/bgp_vty.c: (peer_rsclient_set_vty) lock rsclient list peer
reference
(peer_rsclient_unset_vty) ditto, but unlock same reference
* bgpd/bgpd.c: (peer_free) handle frees of info to be kept for lifetime
of struct peer.
(peer_lock,peer_unlock) peer refcount helpers
(peer_new) add initial refcounts
(peer_create,peer_create_accept) lock peer as appropriate
(peer_delete) unlock as appropriate, move out some free's to
peer_free.
(peer_group_bind,peer_group_unbind) peer refcounting as
appropriate.
(bgp_create) check CALLOC return value.
(bgp_terminate) free workqueues too.
* lib/memtypes.c: Add MTYPE_BGP_PROCESS_QUEUE and
MTYPE_BGP_CLEAR_NODE_QUEUE
|
|
[backport candidate]
|
|
Fixes bugzilla #89. [backport candidate]
|
|
deleting fix. Avoid leaking bgp->group, bgp->peer and bgp->rsclient
lists.
[backport candidate]
|
|
[backport candidate]
|
|
neighbor x.x.x.x routemap [export|import] commands work again.
Fixes bugzilla #184. [backport candidate]
|
|
* bgp_fsm.h: Add extern qualifier to exported functions
* bgp_nexthop.c: add static to nexthop specific globals
* *.h: Add guard defines
|
|
* bgp_routemap.c: add semi-colons to VTY_GET_* to match vty.h change
|
|
* bgp_network.c: (bgp_accept) use XSTRDUP
* bgpd.c: (peer_delete) XFREE the correct memtype, not free.
(peer_create) use XSTRDUP
* bgp_packet.c: (bgp_stream_dup) deleted, stream_dup should be used
(various) update -> s/bgp_stream_dup/stream_dup
|
|
* bgp_fsm.c: (bgp_stop) use sockunion_free, not XFREE..
* bgp_network.c: (bgp_getsockname) ditto
* bgp_routemap.c: (route_match_peer) ditto, als use a ret value and
remove one sockunion_free.
* bgpd.c: (peer_delete) ditto
|
|
Implement non-blocking zclient I/O with buffering.
* zclient.h (struct zclient): Add two fields to support non-blocking
I/O: struct buffer *wb, and struct thread *t_write.
(zclient_free): Remove function.
(zebra_redistribute_send): Change 2nd arg from socket fd to
struct zclient * (needed to support non-blocking I/O and buffering).
(zclient_send_message): New function to send an arbitrary
message with non-blocking I/O.
* zclient.c (zclient_new): Create write buffer.
(zclient_free): Remove unused function.
(zclient_stop): Must cancel new t_write thread. Also, reset
all buffers: ibuf, obuf, and wb.
(zclient_failed): New helper function for typical error handling.
(zclient_flush_data): New thread to flush queued data.
(zclient_send_message): New function to send the message in
zclient->obuf to zebra using non-blocking I/O and buffering.
(zebra_message_send, zapi_ipv4_route, zapi_ipv6_route): Use
new zclient_send_message function instead of calling writen.
(zclient_start): Set socket non-blocking. Also, change 2nd arg
to zebra_redistribute_send from zclient->sock to zclient.
(zebra_redistribute_send): Change 2nd arg to struct zclient *.
Can now use zclient->obuf to assemble the message instead of
allocating a temporary stream. And call zclient_send_message to
send the message instead of writen.
(zclient_read): Convert to support non-blocking I/O by using
stream_read_try instead of deprecated stream_read.
(zclient_redistribute): Change 2nd arg to zebra_redistribute_send
from zclient->sock to zclient.
* ospf6_zebra.c (ospf6_zebra_redistribute, ospf6_zebra_no_redistribute):
Change 2nd arg to zebra_redistribute_send from zclient->sock
to zclient.
* ospf_zebra.c (ospf_zebra_add): Call zclient_send_message instead
of writen.
* rip_zebra.c (rip_redistribute_set, rip_redistribute_unset,
rip_redistribute_clean): Change 2nd arg to zebra_redistribute_send
from zclient->sock to zclient.
* ripng_zebra.c (ripng_redistribute_unset, ripng_redistribute_clean):
Change 2nd arg to zebra_redistribute_send from zclient->sock
to zclient.
* bgp_zebra.c (bgp_redistribute_set, bgp_redistribute_unset):
The 2nd arg to zebra_redistribute_send is now zclient instead of
zclient->sock.
* isis_zebra.h (isis_zebra_finish): Remove declaration of unused
function.
* isis_zebra.c (isis_zebra_route_add_ipv4): Call zclient_send_message
to send the message to zebra instead of calling writen directly, since
zclient_send_message understands non-blocking I/O and will manage
the buffer queue appropriately.
(isis_zebra_finish): Remove unused function, particularly since
the zclient_free function has been removed.
|
|
family node.
[backport candidate]
|
|
* bgp_aspath.[ch], bgp_route.c, bgp_vty.c, bgpd.[ch]: Allow to enable
the length of confederation path segments to be included during the
as-path length check in the best path decision.
|
|
Fix problems when netlink interfaces are renamed (same ifindex used
for a new interface). Start cleaning up some problems with the way
interface names are handled.
* interface.c: (if_new_intern_ifindex) Remove obsolete function.
(if_delete_update) After distributing the interface deletion message,
set ifp->ifindex to IFINDEX_INTERNAL.
(if_dump_vty) Detect pseudo interface by checking if ifp->ifindex is
IFINDEX_INTERNAL.
(zebra_interface) Check return code from interface_cmd.func.
Do not set internal ifindex values to if_new_intern_ifindex(),
since we now use IFINDEX_INTERNAL for all pseudo interfaces.
* kernel_socket.c: (ifm_read) Fix code and comments to reflect that
all internal interfaces now have ifp->ifindex set to IFINDEX_INTERNAL.
* rt_netlink.c: (set_ifindex) New function used to update ifp->ifindex.
Detects interface rename events by checking if that ifindex is already
being used. If it is, delete the old interface before assigning
the ifindex to the new interface.
(netlink_interface, netlink_link_change) Call set_ifindex to update
the ifindex.
* if.h: Remove define for IFINDEX_INTERNBASE and add define
IFINDEX_INTERNAL 0, since all internal (i.e. non-kernel) pseudo-
interfaces should have ifindex set to 0.
(if_new) Remove function.
(if_delete_retain) New function to delete an interface without
removing from iflist and freeing the structure.
(ifname2ifindex) New function.
* if.c: (if_new) Remove function (absorb into if_create).
(if_create) Replace function if_new with call to calloc.
Set ifp->ifindex to IFINDEX_INTERNAL. Fix off-by-one error
in assert to check length of interface name. Add error message
if interface with this name already exists.
(if_delete_retain) New function to delete an interface without
removing from iflist and freeing the structure.
(if_delete) Implement with help of if_delete_retain.
(ifindex2ifname) Reimplement using if_lookup_by_index.
(ifname2ifindex) New function to complement ifindex2ifname.
(interface) The interface command should check the name length
and fail with a warning message if it is too long.
(no_interface) Fix spelling in warning message.
(if_nametoindex) Reimplement using if_lookup_by_name.
(if_indextoname, ifaddr_ipv4_lookup) Reimplement using
if_lookup_by_index.
* bgp_zebra.c: (bgp_interface_delete) After deleting, set ifp->ifindex
to IFINDEX_INTERNAL.
* isis_zebra.c: (isis_zebra_if_del) Call if_delete_retain instead
of if_delete, since it is generally not safe to remove interface
structures. After deleting, set ifp->ifindex to IFINDEX_INTERNAL.
(zebra_interface_if_lookup) Tighten up code.
* ospf6_zebra.c: (ospf6_zebra_if_del) Previously, this whole function
was commented out. But this is not safe: we should at least update
the ifindex when the interface is deleted. So the new version
updates the interface status and sets ifp->ifindex to
IFINDEX_INTERNAL.
(ospf6_zebra_route_update) Use if_indextoname properly.
* ospf_vty.c: (show_ip_ospf_interface_sub) Show ifindex and interface
flags to help with debugging.
* ospf_zebra.c: (ospf_interface_delete) After deleting, set ifp->ifindex
to IFINDEX_INTERNAL.
(zebra_interface_if_lookup) Make function static. Tighten up code.
* rip_interface.c: (rip_interface_delete) After deleting, set
ifp->ifindex to IFINDEX_INTERNAL.
* ripng_interface.c: (ripng_interface_delete) After deleting, set
ifp->ifindex to IFINDEX_INTERNAL.
|
|
no particular afi/safi configured.
[backport candidate]
|
|
work again.
|
|
transparent-nexthop" commands.
[merge from GNU Zebra]
|
|
[merge from GNU Zebra]
|
|
community-list cleanup.
[merge from GNU Zebra]
|
|
-> "disable-connected-check".
[merge from GNU Zebra]
|
|
bgpd.[ch]: Add BGP_INFO_STALE flag and end-of-rib support. "bgp
graceful-restart" commands added. Show numbers of individual
messages in "show ip bgp neighbor" command. Final pieces of graceful
restart.
[merge from GNU Zebra]
|
|
capability route-refresh" commands. Route refresh capability is sent
anyway now. Preserve dummy deprecated commands.
[merge from GNU Zebra]
|
|
draft - ie. "neighbor version 4-" commands. Preserve dummy "neighbor
version" command as deprecated.
[merge from GNU Zebra]
|
|
maximum-prefix limit" feature support.
[merge from GNU Zebra]
|
|
* bgpd.[ch], bgp_nexthop.c, bgp_snmp.c: Remove useless bgp_get_master()
function.
* bgp_packet.c: MP AFI_IP update and withdraw parsing.
* bgp_fsm.c: Reset peer synctime in bgp_stop(). bgp_fsm_change_status()
is better place to log about peer status change than bgp_event().
Log in bgp_connect_success().
* bgp_vty.c: Fix typo in comment.
* bgp_attr.c: Better log about unknown attribute.
[merge from GNU Zebra]
|
|
* buffer.h: Fix comment on buffer_getstr to reflect that it now
uses XMALLOC.
* buffer.c: (buffer_getstr) Use XMALLOC(MTYPE_TMP) instead of malloc.
* filter.c: (access_list_remark,ipv6_access_list_remark) Use
argv_concat instead of buffer_getstr.
* if.c: (interface_desc) Use argv_concat instead of buffer_getstr.
* plist.c: (ip_prefix_list_description,ipv6_prefix_list_description)
Use argv_concat instead of buffer_getstr.
* bgp_filter.c: (ip_as_path,no_ip_as_path) Use argv_concat instead
of buffer_getstr.
* bgp_route.c: (bgp_show_regexp) Fix memory leak: need to free string
returned by buffer_getstr.
(bgp_show_community) Must use XFREE instead of free on string
returned by buffer_getstr.
* bgp_routemap.c: (set_community) Must use XFREE instead of free
on string returned by buffer_getstr.
* bgp_vty.c: (neighbor_description) Use argv_concat instead of
buffer_getstr.
|
|
if old one is flaged as BGP_INFO_ATTR_CHANGED.
|
|
configured or not. Being not configured is even better reason to
do it.
|
|
* bgp_packet.c: (bgp_write) set socket to nonblock while writing
this should be generalised. See bugzilla #102. Fix supplied by
wawa@yandex-team.ru (Vladimir Ivanov).
|
|
* *.c: Change level of debug messages to LOG_DEBUG.
|