diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 1999-02-06 23:07:48 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 1999-02-06 23:07:48 +0000 |
commit | 7a8f98082d969cb672b82334a0d23e0b8d6630a7 (patch) | |
tree | 31d5ff2ac464ce3ddbc37cab625ab2dcceaf7bbd /sys/nfs/nfs_vnops.c | |
parent | 2f060cb43225b4e5b0f50721ed89ac986b286a20 (diff) |
Use bitwise operations to extract high and low words from the quad
in txdr_hyper. This should be more portable than casting to an array
of ints and pulling out the two 32-bit words (this produced incorrect
results on alpha for the high word for filesystems < 4gig). As a side
effect, txdr_hyper now takes a u_quad_t as its first arg, not u_quad_t *.
Diffstat (limited to 'sys/nfs/nfs_vnops.c')
-rw-r--r-- | sys/nfs/nfs_vnops.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/nfs/nfs_vnops.c b/sys/nfs/nfs_vnops.c index 3804d47504d..e09bf34e690 100644 --- a/sys/nfs/nfs_vnops.c +++ b/sys/nfs/nfs_vnops.c @@ -1,4 +1,4 @@ -/* $OpenBSD: nfs_vnops.c,v 1.23 1999/01/10 20:06:51 millert Exp $ */ +/* $OpenBSD: nfs_vnops.c,v 1.24 1999/02/06 23:07:46 millert Exp $ */ /* $NetBSD: nfs_vnops.c,v 1.62.4.1 1996/07/08 20:26:52 jtc Exp $ */ /* @@ -954,7 +954,7 @@ nfs_readrpc(vp, uiop, cred) nfsm_fhtom(vp, v3); nfsm_build(tl, u_int32_t *, NFSX_UNSIGNED * 3); if (v3) { - txdr_hyper(&uiop->uio_offset, tl); + txdr_hyper(uiop->uio_offset, tl); *(tl + 2) = txdr_unsigned(len); } else { *tl++ = txdr_unsigned(uiop->uio_offset); @@ -1021,7 +1021,7 @@ nfs_writerpc(vp, uiop, cred, iomode, must_commit) nfsm_fhtom(vp, v3); if (v3) { nfsm_build(tl, u_int32_t *, 5 * NFSX_UNSIGNED); - txdr_hyper(&uiop->uio_offset, tl); + txdr_hyper(uiop->uio_offset, tl); tl += 2; *tl++ = txdr_unsigned(len); *tl++ = txdr_unsigned(*iomode); @@ -2503,7 +2503,7 @@ nfs_commit(vp, offset, cnt, cred, procp) nfsm_reqhead(vp, NFSPROC_COMMIT, NFSX_FH(1)); nfsm_fhtom(vp, 1); nfsm_build(tl, u_int32_t *, 3 * NFSX_UNSIGNED); - txdr_hyper(&offset, tl); + txdr_hyper(offset, tl); tl += 2; *tl = txdr_unsigned(cnt); nfsm_request(vp, NFSPROC_COMMIT, procp, cred); |