]> git.neil.brown.name Git - LaFS.git/commitdiff
correct arg to kfree in refile
authorNeilBrown <neilb@suse.de>
Thu, 10 Jun 2010 05:39:38 +0000 (15:39 +1000)
committerNeilBrown <neilb@suse.de>
Sun, 13 Jun 2010 07:19:59 +0000 (17:19 +1000)
'b' is a struct-block, technically a virtual type.
Need to get container_of - dblk in this case - before calling
kfree.

Signed-off-by: NeilBrown <neilb@suse.de>
index.c

diff --git a/index.c b/index.c
index 93e4e61cc5ee286084fc01b90dfa9566d7001bb2..d866af5623b562c52812501e6862643065cf679b 100644 (file)
--- a/index.c
+++ b/index.c
@@ -976,7 +976,7 @@ void lafs_refile(struct block *b, int dec)
                        lafs_inode_checkpin(checkpin);
 
                if (free_me)
-                       kfree(b);
+                       kfree(dblk(b));
                b = NULL;
                if (next) {
                        b = next;