projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4804b38
)
Btrfs: fix page leakage
author
Josef Bacik
<jbacik@fusionio.com>
Fri, 5 Oct 2012 20:53:34 +0000
(16:53 -0400)
committer
Chris Mason
<chris.mason@fusionio.com>
Tue, 9 Oct 2012 13:20:56 +0000
(09:20 -0400)
Alloc_dummy_extent_buffer will not free the first page in the eb array if we
fail to allocate a page, fix this. Thanks,
Reported-by: David Sterba <dave@jikos.cz>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
fs/btrfs/extent_io.c
patch
|
blob
|
history
diff --git
a/fs/btrfs/extent_io.c
b/fs/btrfs/extent_io.c
index 7dc69b38548df0874be2ca728f7c582a69f38c69..64dc93f64bc01d624aa85dcf11e6215a6d027611 100644
(file)
--- a/
fs/btrfs/extent_io.c
+++ b/
fs/btrfs/extent_io.c
@@
-4104,7
+4104,7
@@
struct extent_buffer *alloc_dummy_extent_buffer(u64 start, unsigned long len)
return eb;
err:
- for (i--; i > 0; i--)
+ for (i--; i >
=
0; i--)
__free_page(eb->pages[i]);
__free_extent_buffer(eb);
return NULL;