Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 19 Dec 2025 09:19:12 +0000
From:      Olivier Certner <olce@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: c3f9ca7ab109 - stable/14 - sys/rpc: UNIX auth: Style: Remove unnecessary headers, minor changes
Message-ID:  <69451890.3d351.834849d@gitrepo.freebsd.org>

index | next in thread | raw e-mail

The branch stable/14 has been updated by olce:

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

commit c3f9ca7ab109be27a1f8d6a1745669ba6b4c9790
Author:     Olivier Certner <olce@FreeBSD.org>
AuthorDate: 2025-10-07 17:10:12 +0000
Commit:     Olivier Certner <olce@FreeBSD.org>
CommitDate: 2025-12-19 09:16:45 +0000

    sys/rpc: UNIX auth: Style: Remove unnecessary headers, minor changes
    
    MFC after:      2 days
    Sponsored by:   The FreeBSD Foundation
    
    (cherry picked from commit a4105a5d4e179aa1ef661ee45d6008e83fefd2a7)
---
 sys/rpc/authunix_prot.c | 9 +++------
 sys/rpc/svc_auth_unix.c | 4 +---
 2 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/sys/rpc/authunix_prot.c b/sys/rpc/authunix_prot.c
index e72a28130882..d863cdde9101 100644
--- a/sys/rpc/authunix_prot.c
+++ b/sys/rpc/authunix_prot.c
@@ -44,8 +44,7 @@ static char *sccsid = "@(#)authunix_prot.c	2.1 88/07/29 4.0 RPCSRC";
 
 #include <sys/param.h>
 #include <sys/jail.h>
-#include <sys/kernel.h>
-#include <sys/systm.h>
+#include <sys/libkern.h>
 #include <sys/ucred.h>
 
 #include <rpc/types.h>
@@ -74,12 +73,10 @@ xdr_authunix_parms(XDR *xdrs, uint32_t *time, struct xucred *cred)
 		namelen = strlen(hostbuf);
 		if (namelen > AUTH_SYS_MAX_HOSTNAME)
 			namelen = AUTH_SYS_MAX_HOSTNAME;
-	} else {
+	} else
 		namelen = 0;
-	}
 
-	if (!xdr_uint32_t(xdrs, time)
-	    || !xdr_uint32_t(xdrs, &namelen))
+	if (!xdr_uint32_t(xdrs, time) || !xdr_uint32_t(xdrs, &namelen))
 		return (FALSE);
 
 	/*
diff --git a/sys/rpc/svc_auth_unix.c b/sys/rpc/svc_auth_unix.c
index 7222fd6d95c0..6d2cb2359ffd 100644
--- a/sys/rpc/svc_auth_unix.c
+++ b/sys/rpc/svc_auth_unix.c
@@ -45,8 +45,6 @@ static char *sccsid = "@(#)svc_auth_unix.c	2.3 88/08/01 4.0 RPCSRC";
  */
 
 #include <sys/param.h>
-#include <sys/lock.h>
-#include <sys/mutex.h>
 #include <sys/systm.h>
 #include <sys/ucred.h>
 
@@ -135,7 +133,7 @@ _svcauth_unix(struct svc_req *rqst, struct rpc_msg *msg)
 				buf++;
 		}
 		xcr->cr_ngroups = MIN(supp_ngroups + 1, XU_NGROUPS);
-	} else if (! xdr_authunix_parms(&xdrs, &time, xcr))
+	} else if (!xdr_authunix_parms(&xdrs, &time, xcr))
 		goto badcred;
 
 	rqst->rq_verf = _null_auth;


help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?69451890.3d351.834849d>