diff options
author | Evgeniy Dushistov <dushistov@mail.ru> | 2006-06-25 08:47:28 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-25 13:01:04 -0400 |
commit | f391475812ba39afa322c835217ffe936f5e754a (patch) | |
tree | d5bf0a5ec79b0bebe87988734c316b18360f42a8 /fs/ufs/inode.c | |
parent | 96710b29e05f3b470bc4206366021b56e28d5208 (diff) |
[PATCH] ufs: missed brelse and wrong baseblk
This patch fixes two bugs, which introduced by previous patches:
1) Missed "brelse"
2) Sometimes "baseblk" may be wrongly calculated, if i_size is equal to
zero, which lead infinite cycle in "mpage_writepages".
Signed-off-by: Evgeniy Dushistov <dushistov@mail.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/ufs/inode.c')
-rw-r--r-- | fs/ufs/inode.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/ufs/inode.c b/fs/ufs/inode.c index 72282043a8f4..01c5f19cbabe 100644 --- a/fs/ufs/inode.c +++ b/fs/ufs/inode.c | |||
@@ -175,6 +175,7 @@ ufs_clear_frags(struct inode *inode, sector_t beg, | |||
175 | for (++beg; beg < end; ++beg) { | 175 | for (++beg; beg < end; ++beg) { |
176 | bh = sb_getblk(inode->i_sb, beg); | 176 | bh = sb_getblk(inode->i_sb, beg); |
177 | ufs_clear_frag(inode, bh); | 177 | ufs_clear_frag(inode, bh); |
178 | brelse(bh); | ||
178 | } | 179 | } |
179 | return res; | 180 | return res; |
180 | } | 181 | } |