mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 18:27:21 +00:00
ospfd: Cleanup set but unused variables
There existed some variables set but never used. Clean this up. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
2acf1ad1dd
commit
6e3e2c6d5f
@ -670,8 +670,7 @@ static int ospf_abr_translate_nssa(struct ospf_area *area, struct ospf_lsa *lsa)
|
|||||||
* originate translated LSA
|
* originate translated LSA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if ((new = ospf_translated_nssa_originate(area->ospf, lsa))
|
if (ospf_translated_nssa_originate(area->ospf, lsa) == NULL) {
|
||||||
== NULL) {
|
|
||||||
if (IS_DEBUG_OSPF_NSSA)
|
if (IS_DEBUG_OSPF_NSSA)
|
||||||
zlog_debug(
|
zlog_debug(
|
||||||
"ospf_abr_translate_nssa(): Could not translate "
|
"ospf_abr_translate_nssa(): Could not translate "
|
||||||
|
@ -158,12 +158,12 @@ const char *ospf_timeval_dump(struct timeval *t, char *buf, size_t size)
|
|||||||
#define HOUR_IN_SECONDS (60*MINUTE_IN_SECONDS)
|
#define HOUR_IN_SECONDS (60*MINUTE_IN_SECONDS)
|
||||||
#define DAY_IN_SECONDS (24*HOUR_IN_SECONDS)
|
#define DAY_IN_SECONDS (24*HOUR_IN_SECONDS)
|
||||||
#define WEEK_IN_SECONDS (7*DAY_IN_SECONDS)
|
#define WEEK_IN_SECONDS (7*DAY_IN_SECONDS)
|
||||||
unsigned long w, d, h, m, s, ms, us;
|
unsigned long w, d, h, m, ms, us;
|
||||||
|
|
||||||
if (!t)
|
if (!t)
|
||||||
return "inactive";
|
return "inactive";
|
||||||
|
|
||||||
w = d = h = m = s = ms = us = 0;
|
w = d = h = m = ms = 0;
|
||||||
memset(buf, 0, size);
|
memset(buf, 0, size);
|
||||||
|
|
||||||
us = t->tv_usec;
|
us = t->tv_usec;
|
||||||
|
@ -1557,8 +1557,8 @@ struct ospf_lsa *ospf_opaque_lsa_install(struct ospf_lsa *lsa, int rt_recalc)
|
|||||||
ospf_lsa_unlock(&oipi->lsa);
|
ospf_lsa_unlock(&oipi->lsa);
|
||||||
oipi->lsa = ospf_lsa_lock(lsa);
|
oipi->lsa = ospf_lsa_lock(lsa);
|
||||||
}
|
}
|
||||||
/* Register the new lsa entry and get its control info. */
|
/* Register the new lsa entry */
|
||||||
else if ((oipi = register_opaque_lsa(lsa)) == NULL) {
|
else if (register_opaque_lsa(lsa) == NULL) {
|
||||||
flog_warn(EC_OSPF_LSA,
|
flog_warn(EC_OSPF_LSA,
|
||||||
"ospf_opaque_lsa_install: register_opaque_lsa() ?");
|
"ospf_opaque_lsa_install: register_opaque_lsa() ?");
|
||||||
goto out;
|
goto out;
|
||||||
|
@ -1002,7 +1002,6 @@ static int ospf_distribute_list_update_timer(struct thread *thread)
|
|||||||
void ospf_distribute_list_update(struct ospf *ospf, int type,
|
void ospf_distribute_list_update(struct ospf *ospf, int type,
|
||||||
unsigned short instance)
|
unsigned short instance)
|
||||||
{
|
{
|
||||||
struct route_table *rt;
|
|
||||||
struct ospf_external *ext;
|
struct ospf_external *ext;
|
||||||
void **args = XCALLOC(MTYPE_OSPF_DIST_ARGS, sizeof(void *) * 2);
|
void **args = XCALLOC(MTYPE_OSPF_DIST_ARGS, sizeof(void *) * 2);
|
||||||
|
|
||||||
@ -1011,7 +1010,7 @@ void ospf_distribute_list_update(struct ospf *ospf, int type,
|
|||||||
|
|
||||||
/* External info does not exist. */
|
/* External info does not exist. */
|
||||||
ext = ospf_external_lookup(ospf, type, instance);
|
ext = ospf_external_lookup(ospf, type, instance);
|
||||||
if (!ext || !(rt = EXTERNAL_INFO(ext))) {
|
if (!ext || !EXTERNAL_INFO(ext)) {
|
||||||
XFREE(MTYPE_OSPF_DIST_ARGS, args);
|
XFREE(MTYPE_OSPF_DIST_ARGS, args);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user