diff options
author | alfred <alfred@FreeBSD.org> | 2002-08-15 21:52:22 +0000 |
---|---|---|
committer | alfred <alfred@FreeBSD.org> | 2002-08-15 21:52:22 +0000 |
commit | 6d7e27acebf039aa472ab2df41baa447cae9e1cc (patch) | |
tree | 395ed6420f6be62e72b3bf181d1b5e4bfbb1e8fa /sys/nfsclient | |
parent | 0684d0ba09247ef783f59da1a02483563fb16490 (diff) | |
download | FreeBSD-src-6d7e27acebf039aa472ab2df41baa447cae9e1cc.zip FreeBSD-src-6d7e27acebf039aa472ab2df41baa447cae9e1cc.tar.gz |
Remove a case of exposing 'struct ucred' to userspace. Use a struct xucred
for LOCKD_MSG instead.
Requested by: rwatson
Diffstat (limited to 'sys/nfsclient')
-rw-r--r-- | sys/nfsclient/nfs_lock.c | 2 | ||||
-rw-r--r-- | sys/nfsclient/nfs_lock.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sys/nfsclient/nfs_lock.c b/sys/nfsclient/nfs_lock.c index 404fce9..ee028dc 100644 --- a/sys/nfsclient/nfs_lock.c +++ b/sys/nfsclient/nfs_lock.c @@ -139,7 +139,7 @@ nfs_dolock(struct vop_advlock_args *ap) msg.lm_fh_len = NFS_ISV3(vp) ? VTONFS(vp)->n_fhsize : NFSX_V2FH; bcopy(VTONFS(vp)->n_fhp, msg.lm_fh, msg.lm_fh_len); msg.lm_nfsv3 = NFS_ISV3(vp); - msg.lm_cred = *(td->td_ucred); + cru2x(td->td_ucred, &msg.lm_cred); /* * Open the lock fifo. If for any reason we don't find the fifo, it diff --git a/sys/nfsclient/nfs_lock.h b/sys/nfsclient/nfs_lock.h index af99bc5..e4bb794 100644 --- a/sys/nfsclient/nfs_lock.h +++ b/sys/nfsclient/nfs_lock.h @@ -72,7 +72,7 @@ typedef struct __lock_msg { struct sockaddr_storage lm_addr; /* The address. */ int lm_nfsv3; /* If NFS version 3. */ size_t lm_fh_len; /* The file handle length. */ - struct ucred lm_cred; /* user cred for lock req */ + struct xucred lm_cred; /* user cred for lock req */ u_int8_t lm_fh[NFS_SMALLFH];/* The file handle. */ } LOCKD_MSG; |