]> git.proxmox.com Git - mirror_frr.git/blobdiff - ospf6d/ospf6_intra.c
Merge pull request #12798 from donaldsharp/rib_match_multicast
[mirror_frr.git] / ospf6d / ospf6_intra.c
index f3fd9dab66e4f2a678a28e0bc5f2c61a8ebd19ec..e7ce2f5f723e1769c07f6f394990f01823c9fe3a 100644 (file)
@@ -1,21 +1,6 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * Copyright (C) 2003 Yasuhiro Ohara
- *
- * This file is part of GNU Zebra.
- *
- * 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 Zebra 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>
@@ -1765,10 +1750,8 @@ void ospf6_intra_prefix_lsa_add(struct ospf6_lsa *lsa)
        intra_prefix_lsa =
                (struct ospf6_intra_prefix_lsa *)OSPF6_LSA_HEADER_END(
                        lsa->header);
-       if (intra_prefix_lsa->ref_type == htons(OSPF6_LSTYPE_ROUTER))
-               ospf6_linkstate_prefix(intra_prefix_lsa->ref_adv_router,
-                                      intra_prefix_lsa->ref_id, &ls_prefix);
-       else if (intra_prefix_lsa->ref_type == htons(OSPF6_LSTYPE_NETWORK))
+       if (intra_prefix_lsa->ref_type == htons(OSPF6_LSTYPE_ROUTER) ||
+           intra_prefix_lsa->ref_type == htons(OSPF6_LSTYPE_NETWORK))
                ospf6_linkstate_prefix(intra_prefix_lsa->ref_adv_router,
                                       intra_prefix_lsa->ref_id, &ls_prefix);
        else {
@@ -2010,7 +1993,7 @@ void ospf6_intra_prefix_lsa_remove(struct ospf6_lsa *lsa)
                        break;
                prefix_num--;
 
-               memset(&prefix, 0, sizeof(struct prefix));
+               memset(&prefix, 0, sizeof(prefix));
                prefix.family = AF_INET6;
                prefix.prefixlen = op->prefix_length;
                ospf6_prefix_in6_addr(&prefix.u.prefix6, intra_prefix_lsa, op);