]> git.proxmox.com Git - mirror_frr.git/blobdiff - ospfd/ospf_ri.c
Merge pull request #13120 from Pdoijode/ospf-virtual-link-crash
[mirror_frr.git] / ospfd / ospf_ri.c
index 0efa6ca4d52abb84d9a56e19af2977021d2da23e..0179f9ee0bea7ee41ffc55cec96870e786b1c27d 100644 (file)
@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * This is an implementation of RFC4970 Router Information
  * with support of RFC5088 PCE Capabilites announcement
@@ -5,22 +6,6 @@
  * Module name: Router Information
  * Author: Olivier Dugeon <olivier.dugeon@orange.com>
  * Copyright (C) 2012 - 2017 Orange Labs http://www.orange.com/
- *
- * This file is part of GNU Quagga.
- *
- * GNU Zebra is free software; you can redistribute it and/or modify it
- * under the terms of the GNU General Public License as published by the
- * Free Software Foundation; either version 2, or (at your option) any
- * later version.
- *
- * GNU Quagga is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; see the file COPYING; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  */
 
 #include <zebra.h>
@@ -35,7 +20,7 @@
 #include "vty.h"
 #include "stream.h"
 #include "log.h"
-#include "thread.h"
+#include "frrevent.h"
 #include "hash.h"
 #include "sockunion.h" /* for inet_aton() */
 #include "mpls.h"
@@ -66,7 +51,7 @@
 static struct ospf_router_info OspfRI;
 
 /*------------------------------------------------------------------------------*
- * Followings are initialize/terminate functions for Router Information
+ * Following are initialize/terminate functions for Router Information
  *handling.
  *------------------------------------------------------------------------------*/
 
@@ -90,7 +75,7 @@ int ospf_router_info_init(void)
 
        zlog_info("RI (%s): Initialize Router Information", __func__);
 
-       memset(&OspfRI, 0, sizeof(struct ospf_router_info));
+       memset(&OspfRI, 0, sizeof(OspfRI));
        OspfRI.enabled = false;
        OspfRI.registered = 0;
        OspfRI.scope = OSPF_OPAQUE_AS_LSA;
@@ -232,7 +217,7 @@ static struct ospf_ri_area_info *lookup_by_area(struct ospf_area *area)
 }
 
 /*------------------------------------------------------------------------*
- * Followings are control functions for ROUTER INFORMATION parameters
+ * Following are control functions for ROUTER INFORMATION parameters
  *management.
  *------------------------------------------------------------------------*/
 
@@ -668,7 +653,7 @@ void ospf_router_info_update_sr(bool enable, struct sr_node *srn)
 }
 
 /*------------------------------------------------------------------------*
- * Followings are callback functions against generic Opaque-LSAs handling.
+ * Following are callback functions against generic Opaque-LSAs handling.
  *------------------------------------------------------------------------*/
 static void ospf_router_info_ism_change(struct ospf_interface *oi,
                                        int old_state)
@@ -693,7 +678,7 @@ static void ospf_router_info_ism_change(struct ospf_interface *oi,
 }
 
 /*------------------------------------------------------------------------*
- * Followings are OSPF protocol processing functions for ROUTER INFORMATION
+ * Following are OSPF protocol processing functions for ROUTER INFORMATION
  *------------------------------------------------------------------------*/
 
 static void build_tlv_header(struct stream *s, struct tlv_header *tlvh)
@@ -1223,7 +1208,7 @@ static int ospf_router_info_lsa_update(struct ospf_lsa *lsa)
 }
 
 /*------------------------------------------------------------------------*
- * Followings are vty session control functions.
+ * Following are vty session control functions.
  *------------------------------------------------------------------------*/
 
 #define check_tlv_size(size, msg)                                              \
@@ -1660,7 +1645,7 @@ static void ospf_router_info_config_write_router(struct vty *vty)
 }
 
 /*------------------------------------------------------------------------*
- * Followings are vty command functions.
+ * Following are vty command functions.
  *------------------------------------------------------------------------*/
 /* Simple wrapper schedule RI LSA action in function of the scope */
 static void ospf_router_info_schedule(enum lsa_opcode opcode)