mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 13:53:33 +00:00
[GFS2] Fix bug in directory code
This was a nasty bug which resulted in corruption of hash tables in the directory code with larger directories. We forgot to increment a pointer in the read/write routines internal to the directory code. Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
This commit is contained in:
parent
de9b75d31e
commit
899bb26450
1 changed files with 2 additions and 0 deletions
|
@ -215,6 +215,7 @@ static int gfs2_dir_write_data(struct gfs2_inode *ip, const char *buf,
|
||||||
if (error)
|
if (error)
|
||||||
goto fail;
|
goto fail;
|
||||||
|
|
||||||
|
buf += amount;
|
||||||
copied += amount;
|
copied += amount;
|
||||||
lblock++;
|
lblock++;
|
||||||
dblock++;
|
dblock++;
|
||||||
|
@ -335,6 +336,7 @@ static int gfs2_dir_read_data(struct gfs2_inode *ip, char *buf,
|
||||||
if (error)
|
if (error)
|
||||||
goto fail;
|
goto fail;
|
||||||
|
|
||||||
|
buf += amount;
|
||||||
copied += amount;
|
copied += amount;
|
||||||
lblock++;
|
lblock++;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue