a) EIGRP was having issues with the prefix created as part
of the topology destination. Make this just a part of the
topology data structure instead of allocating it.
b) EIGRP was not freeing up any memory associated with
the network table. Free it.
c) EIGRP was confusing zebra shutdown as part of the deletion
of the last eigrp data structure. This was inappropriate it
should be part of the `I'm just shutting down`.
d) The QOBJ was not being properly freed, free it.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This is a first in a series of commits, whose goal is to rename
the thread system in FRR to an event system. There is a continual
problem where people are confusing `struct thread` with a true
pthread. In reality, our entire thread.c is an event system.
In this commit rename the thread.[ch] files to event.[ch].
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Same as previous commit -- convert most DEFINE_MTYPE into the _STATIC
variant, and move the remaining non-static ones to appropriate places.
Signed-off-by: David Lamparter <equinox@diac24.net>
Rename struct eigrp_nexthop_entry to struct eigrp_route_descriptor
Rename struct eigrp_prefix_entry to struct eigrp_prefix_descriptor
Fix all the associated function names as well.
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Signed-off-by: Donnie SAvage <diivious@hotmail.com>
The following types are nonstandard:
- u_char
- u_short
- u_int
- u_long
- u_int8_t
- u_int16_t
- u_int32_t
Replace them with the C99 standard types:
- uint8_t
- unsigned short
- unsigned int
- unsigned long
- uint8_t
- uint16_t
- uint32_t
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
1) strlen(buf) on an uninted value is the wrong thing to do
we should be getting sizeof(buf)
2) tlv is not freed in this error case, so let's free it up.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
When we receive a reply for a prefix we no longer
have we should note the issue and move on instead
of crashing eigrp.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
We need one struct eigrp_interface per ifp structure
not a ifp->info structure with a ei per connected.
Some minor code cleanup as well with macros and
their weird usage.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
There was allot of code cut-n-pasting to
apply the prefix/access lists. Refactor
to simplify code.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
We need to eventually be able to handle multiple
data types to figure out if the distance is better
worse.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
The FSM was never freeing the msg. Since we
do not have a special queue for it, just don't
allocate the memory. In the future we can put
this back.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
The FIFO really was a LIFO for some reason.
Push new packets onto the top, always pull from the bottom.
This allows eigrp neighbors to come up. Topotests
eigrp-topo1( in a topotest PR ) now form neighbors
with itself. With this commit.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Store the neighbor information( if available ) in the packet
data that we are sending. This will allow in a future commit
the ability to fixup the outgoing ack we are sending.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Recent additions to prefix_copy to check afi type exposed
an issue with eigrp setting the wrong afi type for a `struct prefix`.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
The FSF's address changed, and we had a mixture of comment styles for
the GPL file header. (The style with * at the beginning won out with
580 to 141 in existing files.)
Note: I've intentionally left intact other "variations" of the copyright
header, e.g. whether it says "Zebra", "Quagga", "FRR", or nothing.
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
Please Note, I will be redoing this commit message with
more information.
Additionally I will rework the lib/* changes into their
own commits.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>