hello,

path is freed twice when encounter bad inode, once before goto make_bad, once at label make_bad.


--- a/inode.c   Fri Aug 10 16:22:09 2007 -0400
+++ b/inode.c   Mon Aug 20 14:27:03 2007 +0800
@@ -142,8 +142,6 @@ void btrfs_read_locked_inode(struct inod
        return;

 make_bad:
-       btrfs_release_path(root, path);
-       btrfs_free_path(path);
        mutex_unlock(&root->fs_info->fs_mutex);
        make_bad_inode(inode);
 }


The issue was found after I try to create cross subvolume hardlink on the fs. I find "forbid cross subvolume renames and hardlinks" is the TODO list and feel that it's easy to implement it (check BTRFS_I(src)->root == BTRFS_I(dest dir)->root). what else need to consider? thank you!

YZ

_______________________________________________
Btrfs-devel mailing list
[email protected]
http://oss.oracle.com/mailman/listinfo/btrfs-devel

Reply via email to