mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 03:36:19 +00:00
Fix memory corruption caused by nfsd readdir+
Commit 8177e6d6df
("nfsd: clean up
readdirplus encoding") introduced single character typo in nfs3 readdir+
implementation. Unfortunately that typo has quite bad side effects:
random memory corruption, followed (on my box) with immediate
spontaneous box reboot.
Using 'p1' instead of 'p' fixes my Linux box rebooting whenever VMware
ESXi box tries to list contents of my home directory.
Signed-off-by: Petr Vandrovec <petr@vandrovec.name>
Cc: "J. Bruce Fields" <bfields@fieldses.org>
Cc: Neil Brown <neilb@suse.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
156171c71a
commit
479c2553af
1 changed files with 1 additions and 1 deletions
|
@ -958,7 +958,7 @@ encode_entry(struct readdir_cd *ccd, const char *name, int namlen,
|
|||
p1 = encode_entry_baggage(cd, p1, name, namlen, ino);
|
||||
|
||||
if (plus)
|
||||
p = encode_entryplus_baggage(cd, p1, name, namlen);
|
||||
p1 = encode_entryplus_baggage(cd, p1, name, namlen);
|
||||
|
||||
/* determine entry word length and lengths to go in pages */
|
||||
num_entry_words = p1 - tmp;
|
||||
|
|
Loading…
Reference in a new issue