]> git.proxmox.com Git - mirror_frr.git/blobdiff - bgpd/bgp_bfd.c
Merge pull request #1854 from qlyoung/integer-standards-compliance
[mirror_frr.git] / bgpd / bgp_bfd.c
index 9b5202ff9109e4ef0cd86520e993dd44cee92e2d..c7d624987062486b0c5a16f388a8158f26d8d65f 100644 (file)
@@ -101,7 +101,7 @@ static void bgp_bfd_peer_sendmsg(struct peer *peer, int command)
 
        bfd_info = (struct bfd_info *)peer->bfd_info;
 
-       if (peer->bgp && (peer->bgp->inst_type == BGP_INSTANCE_TYPE_VRF))
+       if (peer->bgp->inst_type == BGP_INSTANCE_TYPE_VRF)
                vrf_id = peer->bgp->vrf_id;
 
        if (command == ZEBRA_BFD_DEST_DEREGISTER) {
@@ -212,9 +212,8 @@ static void bgp_bfd_update_type(struct peer *peer)
                if ((multihop
                     && !CHECK_FLAG(bfd_info->flags,
                                    BFD_FLAG_BFD_TYPE_MULTIHOP))
-                   || (!multihop
-                       && CHECK_FLAG(bfd_info->flags,
-                                     BFD_FLAG_BFD_TYPE_MULTIHOP))) {
+                   || (!multihop && CHECK_FLAG(bfd_info->flags,
+                                               BFD_FLAG_BFD_TYPE_MULTIHOP))) {
                        bgp_bfd_peer_sendmsg(peer, ZEBRA_BFD_DEST_DEREGISTER);
                        bgp_bfd_peer_sendmsg(peer, ZEBRA_BFD_DEST_REGISTER);
                }
@@ -303,13 +302,13 @@ static int bgp_bfd_dest_update(int command, struct zclient *zclient,
                prefix2str(&dp, buf[0], sizeof(buf[0]));
                if (ifp) {
                        zlog_debug(
-                               "Zebra: vrf %d interface %s bfd destination %s %s",
+                               "Zebra: vrf %u interface %s bfd destination %s %s",
                                vrf_id, ifp->name, buf[0],
                                bfd_get_status_str(status));
                } else {
                        prefix2str(&sp, buf[1], sizeof(buf[1]));
                        zlog_debug(
-                               "Zebra: vrf %d source %s bfd destination %s %s",
+                               "Zebra: vrf %u source %s bfd destination %s %s",
                                vrf_id, buf[1], buf[0],
                                bfd_get_status_str(status));
                }
@@ -384,8 +383,8 @@ static int bgp_bfd_dest_update(int command, struct zclient *zclient,
 /*
  * bgp_bfd_peer_param_set - Set the configured BFD paramter values for peer.
  */
-static int bgp_bfd_peer_param_set(struct peer *peer, u_int32_t min_rx,
-                                 u_int32_t min_tx, u_int8_t detect_mult,
+static int bgp_bfd_peer_param_set(struct peer *peer, uint32_t min_rx,
+                                 uint32_t min_tx, uint8_t detect_mult,
                                  int defaults)
 {
        struct peer_group *group;
@@ -527,7 +526,7 @@ void bgp_bfd_peer_config_write(struct vty *vty, struct peer *peer, char *addr)
 /*
  * bgp_bfd_show_info - Show the peer BFD information.
  */
-void bgp_bfd_show_info(struct vty *vty, struct peer *peer, u_char use_json,
+void bgp_bfd_show_info(struct vty *vty, struct peer *peer, uint8_t use_json,
                       json_object *json_neigh)
 {
        bfd_show_info(vty, (struct bfd_info *)peer->bfd_info,
@@ -572,9 +571,9 @@ DEFUN (neighbor_bfd_param,
        int idx_number_2 = 4;
        int idx_number_3 = 5;
        struct peer *peer;
-       u_int32_t rx_val;
-       u_int32_t tx_val;
-       u_int8_t dm_val;
+       uint32_t rx_val;
+       uint32_t tx_val;
+       uint8_t dm_val;
        int ret;
 
        peer = peer_and_group_lookup_vty(vty, argv[idx_peer]->arg);