summaryrefslogtreecommitdiff
path: root/nfs
diff options
context:
space:
mode:
authorMichael I. Bushnell <mib@gnu.org>1996-03-29 22:10:53 +0000
committerMichael I. Bushnell <mib@gnu.org>1996-03-29 22:10:53 +0000
commitce2be747b563cf9404650dc1e61dc9987d6a0ecb (patch)
tree8986400aaeee7c1d23d641b1226b1e548c1aa643 /nfs
parent4a8dd5b41abfc886a48f09ad61da6902197b52ab (diff)
(netfs_attempt_write): Truncate to THISAMT instead of AMT.
Diffstat (limited to 'nfs')
-rw-r--r--nfs/ops.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/nfs/ops.c b/nfs/ops.c
index 07963f87..ac5ceb98 100644
--- a/nfs/ops.c
+++ b/nfs/ops.c
@@ -377,10 +377,10 @@ netfs_attempt_write (struct netcred *cred, struct node *np,
for (amt = *len; amt;)
{
thisamt = amt;
- if (amt > write_size)
- amt = write_size;
+ if (thisamt > write_size)
+ thisamt = write_size;
- p = nfs_initialize_rpc (NFSPROC_WRITE, cred, amt, &rpcbuf, np, -1);
+ p = nfs_initialize_rpc (NFSPROC_WRITE, cred, thisamt, &rpcbuf, np, -1);
p = xdr_encode_fhandle (p, &np->nn->handle);
*p++ = 0;
*p++ = htonl (offset);