summaryrefslogtreecommitdiffstats
path: root/sys/nfsserver/nfs_serv.c
diff options
context:
space:
mode:
authoriedowse <iedowse@FreeBSD.org>2001-12-18 01:22:09 +0000
committeriedowse <iedowse@FreeBSD.org>2001-12-18 01:22:09 +0000
commit6e9f1df98f816467a63dc5b41cea58f28843e390 (patch)
tree9270c37106f68890c1fcce6d366590e69faa1848 /sys/nfsserver/nfs_serv.c
parentbba76f2085975aeba776356b2556c99b8c882bd5 (diff)
downloadFreeBSD-src-6e9f1df98f816467a63dc5b41cea58f28843e390.zip
FreeBSD-src-6e9f1df98f816467a63dc5b41cea58f28843e390.tar.gz
Avoid passing the variable `tl' to functions that just use it for
temporary storage. In the old NFS code it wasn't at all clear if the value of `tl' was used across or after macro calls, but I'm fairly confident that the convention was to keep its use local. Each ex-macro function now uses a local version of this variable, so all of the double-indirection goes away. The only exception to the `local use' rule for `tl' is nfsm_clget(), which is left unchanged by this commit. Reviewed by: peter
Diffstat (limited to 'sys/nfsserver/nfs_serv.c')
-rw-r--r--sys/nfsserver/nfs_serv.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/sys/nfsserver/nfs_serv.c b/sys/nfsserver/nfs_serv.c
index d0c290c..9452fcd 100644
--- a/sys/nfsserver/nfs_serv.c
+++ b/sys/nfsserver/nfs_serv.c
@@ -244,7 +244,6 @@ nfsrv_getattr(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct vnode *vp = NULL;
nfsfh_t nfh;
fhandle_t *fhp;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, rdonly;
struct mbuf *mb, *mreq;
@@ -449,7 +448,6 @@ nfsrv_lookup(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct vnode *vp, *dirp = NULL;
nfsfh_t nfh;
fhandle_t *fhp;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, len, dirattr_ret = 1;
int v3 = (nfsd->nd_flag & ND_NFSV3), pubflag;
@@ -2055,7 +2053,6 @@ nfsrv_remove(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
caddr_t dpos = nfsd->nd_dpos;
struct ucred *cred = &nfsd->nd_cr;
struct nameidata nd;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, len, dirfor_ret = 1, diraft_ret = 1;
int v3 = (nfsd->nd_flag & ND_NFSV3);
@@ -2153,7 +2150,6 @@ nfsrv_rename(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct sockaddr *nam = nfsd->nd_nam;
caddr_t dpos = nfsd->nd_dpos;
struct ucred *cred = &nfsd->nd_cr;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, len, len2, fdirfor_ret = 1, fdiraft_ret = 1;
int tdirfor_ret = 1, tdiraft_ret = 1;
@@ -2382,7 +2378,6 @@ nfsrv_link(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
caddr_t dpos = nfsd->nd_dpos;
struct ucred *cred = &nfsd->nd_cr;
struct nameidata nd;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, rdonly, len, dirfor_ret = 1, diraft_ret = 1;
int getret = 1, v3 = (nfsd->nd_flag & ND_NFSV3);
@@ -2506,7 +2501,6 @@ nfsrv_symlink(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct vattr va, dirfor, diraft;
struct nameidata nd;
struct vattr *vap = &va;
- u_int32_t *tl;
struct nfsv2_sattr *sp;
char *bpos, *pathcp = (char *)0;
struct uio io;
@@ -2830,7 +2824,6 @@ nfsrv_rmdir(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct sockaddr *nam = nfsd->nd_nam;
caddr_t dpos = nfsd->nd_dpos;
struct ucred *cred = &nfsd->nd_cr;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, len, dirfor_ret = 1, diraft_ret = 1;
int v3 = (nfsd->nd_flag & ND_NFSV3);
@@ -3748,7 +3741,6 @@ nfsrv_statfs(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct ucred *cred = &nfsd->nd_cr;
struct statfs *sf;
struct nfs_statfs *sfp;
- u_int32_t *tl;
caddr_t bpos;
int error = 0, rdonly, getret = 1;
int v3 = (nfsd->nd_flag & ND_NFSV3);
@@ -3825,7 +3817,6 @@ nfsrv_fsinfo(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct sockaddr *nam = nfsd->nd_nam;
caddr_t dpos = nfsd->nd_dpos;
struct ucred *cred = &nfsd->nd_cr;
- u_int32_t *tl;
struct nfsv3_fsinfo *sip;
caddr_t bpos;
int error = 0, rdonly, getret = 1, pref;
@@ -3901,7 +3892,6 @@ nfsrv_pathconf(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp,
struct sockaddr *nam = nfsd->nd_nam;
caddr_t dpos = nfsd->nd_dpos;
struct ucred *cred = &nfsd->nd_cr;
- u_int32_t *tl;
struct nfsv3_pathconf *pc;
caddr_t bpos;
int error = 0, rdonly, getret = 1;
OpenPOWER on IntegriCloud