summaryrefslogtreecommitdiffstats
path: root/ospfd/ospf_sr.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2018-08-20 20:05:53 +0200
committerQuentin Young <qlyoung@cumulusnetworks.com>2018-09-06 22:50:58 +0200
commit266469ebababa2d6949bbd22390010d422a68356 (patch)
treea5b15fdf7d24d393645d2e898350a87a5b59f9d8 /ospfd/ospf_sr.c
parentlib: Modify zlog_warn to vty_out (diff)
downloadfrr-266469ebababa2d6949bbd22390010d422a68356.tar.xz
frr-266469ebababa2d6949bbd22390010d422a68356.zip
ospfd: Cleanup some warnings that were not warnings
1) stream allocation cannot fail 2) some warnings were removed when functions safely ignored the calling parameters being wrong. 3) some warnings were removed when functions did not consider the state as an error since we did not return an error code. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'ospfd/ospf_sr.c')
-rw-r--r--ospfd/ospf_sr.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/ospfd/ospf_sr.c b/ospfd/ospf_sr.c
index 62eca156f..fc8899cc8 100644
--- a/ospfd/ospf_sr.c
+++ b/ospfd/ospf_sr.c
@@ -233,10 +233,6 @@ static int ospf_sr_start(struct ospf *ospf)
srn = hash_get(OspfSR.neighbors, (void *)&(ospf->router_id),
(void *)sr_node_new);
- /* Sanity Check */
- if (srn == NULL)
- return rc;
-
/* Complete & Store self SR Node */
srn->srgb.range_size = OspfSR.srgb.range_size;
srn->srgb.lower_bound = OspfSR.srgb.lower_bound;
@@ -1702,10 +1698,7 @@ DEFUN(ospf_sr_enable,
/* Start Segment Routing */
OspfSR.enabled = true;
- if (!ospf_sr_start(ospf)) {
- zlog_warn("SR: Unable to start Segment Routing. Abort!");
- return CMD_WARNING;
- }
+ ospf_sr_start(ospf);
/* Set Router Information SR parameters */
if (IS_DEBUG_OSPF_EVENT)
@@ -1990,7 +1983,7 @@ DEFUN (sr_prefix_sid,
* update of this Extended Prefix
*/
listnode_add(OspfSR.self->ext_prefix, new);
- zlog_warn(
+ zlog_info(
"Interface for prefix %s/%u not found. Deferred LSA "
"flooding",
inet_ntoa(p.u.prefix4), p.prefixlen);