]> git.proxmox.com Git - mirror_frr.git/blobdiff - sharpd/sharp_vty.c
build: fix new gcc 11.2 warnings
[mirror_frr.git] / sharpd / sharp_vty.c
index 889643f65e818a073bcd06bca480a58085c784f9..2281b3ce2607dfeafb664e1542da6b15822c1e8f 100644 (file)
@@ -104,7 +104,7 @@ DEFPY(watch_nexthop_v6, watch_nexthop_v6_cmd,
                p.family = AF_INET6;
        } else {
                type_import = true;
-               p = *(const struct prefix *)inhop;
+               prefix_copy(&p, inhop);
        }
 
        sharp_nh_tracker_get(&p);
@@ -149,7 +149,7 @@ DEFPY(watch_nexthop_v4, watch_nexthop_v4_cmd,
        }
        else {
                type_import = true;
-               p = *(const struct prefix *)inhop;
+               prefix_copy(&p, inhop);
        }
 
        sharp_nh_tracker_get(&p);