Merge pull request #7077 from ckishimo/debug

ospfd: fix debug ospf nssa prints wrong info
This commit is contained in:
Donald Sharp 2020-09-18 14:56:12 -04:00 committed by GitHub
commit 193ba68dd4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1796,7 +1796,15 @@ struct ospf_lsa *ospf_translated_nssa_originate(struct ospf *ospf,
return NULL;
}
extnew = (struct as_external_lsa *)new;
extnew = (struct as_external_lsa *)new->data;
if ((new = ospf_lsa_install(ospf, NULL, new)) == NULL) {
flog_warn(
EC_OSPF_LSA_INSTALL_FAILURE,
"ospf_lsa_translated_nssa_originate(): Could not install LSA id %s",
inet_ntoa(type7->data->id));
return NULL;
}
if (IS_DEBUG_OSPF_NSSA) {
zlog_debug(
@ -1807,13 +1815,6 @@ struct ospf_lsa *ospf_translated_nssa_originate(struct ospf *ospf,
inet_ntoa(extnew->e[0].fwd_addr));
}
if ((new = ospf_lsa_install(ospf, NULL, new)) == NULL) {
flog_warn(EC_OSPF_LSA_INSTALL_FAILURE,
"ospf_lsa_translated_nssa_originate(): Could not install LSA id %s",
inet_ntoa(type7->data->id));
return NULL;
}
ospf->lsa_originate_count++;
ospf_flood_through_as(ospf, NULL, new);