Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
237df83a
Commit
237df83a
authored
Feb 26, 2004
by
Andrew Morton
Committed by
Linus Torvalds
Feb 26, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] kNFSd: fixes an xdr error by removing the verifier from error return.
From: NeilBrown <neilb@cse.unsw.edu.au>
parent
fdaf729d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
4 deletions
+11
-4
fs/nfsd/nfs4xdr.c
fs/nfsd/nfs4xdr.c
+11
-4
No files found.
fs/nfsd/nfs4xdr.c
View file @
237df83a
...
...
@@ -2091,7 +2091,7 @@ nfsd4_encode_readdir(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_re
{
int
maxcount
;
loff_t
offset
;
u32
*
page
;
u32
*
page
,
*
savep
;
ENCODE_HEAD
;
if
(
nfserr
)
...
...
@@ -2100,6 +2100,7 @@ nfsd4_encode_readdir(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_re
return
nfserr_resource
;
RESERVE_SPACE
(
8
);
/* verifier */
savep
=
p
;
/* XXX: Following NFSv3, we ignore the READDIR verifier for now. */
WRITE32
(
0
);
...
...
@@ -2117,8 +2118,10 @@ nfsd4_encode_readdir(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_re
* pointer and eof field.
*/
maxcount
=
(
maxcount
>>
2
)
-
4
;
if
(
maxcount
<
0
)
return
nfserr_toosmall
;
if
(
maxcount
<
0
)
{
nfserr
=
nfserr_toosmall
;
goto
err_no_verf
;
}
svc_take_page
(
resp
->
rqstp
);
page
=
page_address
(
resp
->
rqstp
->
rq_respages
[
resp
->
rqstp
->
rq_resused
-
1
]);
...
...
@@ -2136,7 +2139,7 @@ nfsd4_encode_readdir(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_re
readdir
->
buffer
==
page
)
nfserr
=
nfserr_toosmall
;
if
(
nfserr
)
return
nfserr
;
goto
err_no_verf
;
if
(
readdir
->
offset
)
xdr_encode_hyper
(
readdir
->
offset
,
offset
);
...
...
@@ -2156,6 +2159,10 @@ nfsd4_encode_readdir(struct nfsd4_compoundres *resp, int nfserr, struct nfsd4_re
resp
->
end
=
resp
->
p
+
PAGE_SIZE
/
4
;
return
0
;
err_no_verf:
p
=
savep
;
ADJUST_ARGS
();
return
nfserr
;
}
static
void
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment