The branch main has been updated by mjg:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=5a4e46f6ec470593be5a3d2d41591e714759e1c0

commit 5a4e46f6ec470593be5a3d2d41591e714759e1c0
Author:     Mateusz Guzik <[email protected]>
AuthorDate: 2021-11-14 17:15:08 +0000
Commit:     Mateusz Guzik <[email protected]>
CommitDate: 2021-11-14 17:15:08 +0000

    net: whack "set but not used" warnings in net/if.c
    
    Sponsored by:   Rubicon Communications, LLC ("Netgate")
---
 sys/net/if.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sys/net/if.c b/sys/net/if.c
index 83a0b07805ee..c7a6706f41df 100644
--- a/sys/net/if.c
+++ b/sys/net/if.c
@@ -746,7 +746,7 @@ if_free(struct ifnet *ifp)
 void
 if_ref(struct ifnet *ifp)
 {
-       u_int old;
+       u_int old __diagused;
 
        /* We don't assert the ifnet list lock here, but arguably should. */
        old = refcount_acquire(&ifp->if_refcount);
@@ -1847,7 +1847,7 @@ fail:
 void
 ifa_ref(struct ifaddr *ifa)
 {
-       u_int old;
+       u_int old __diagused;
 
        old = refcount_acquire(&ifa->ifa_refcnt);
        KASSERT(old > 0, ("%s: ifa %p has 0 refs", __func__, ifa));

Reply via email to