aboutsummaryrefslogtreecommitdiffstats
path: root/btrfs-zero-log.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.cz>2013-03-06 17:32:51 +0100
committerDavid Sterba <dsterba@suse.cz>2013-03-10 16:12:21 +0100
commitdd21bc16ad9bfd87df9311b39dad425ee533eb78 (patch)
tree0d8cd4e374eaeb0dd30f6aa4603d7d6a073280b4 /btrfs-zero-log.c
parentfc61b53da8dba69d2a150ca4fa8faca62c978221 (diff)
downloadbtrfs-progs-dd21bc16ad9bfd87df9311b39dad425ee533eb78.tar.gz
btrfs-progs-dd21bc16ad9bfd87df9311b39dad425ee533eb78.tar.xz
btrfs-progs-dd21bc16ad9bfd87df9311b39dad425ee533eb78.zip
btrfs-progs: separate super_copy out of fs_info
Allocate fs_info::super_copy dynamically of full BTRFS_SUPER_INFO_SIZE and use it directly for saving superblock to disk. This fixes incorrect superblock checksum after mkfs. Signed-off-by: David Sterba <dsterba@suse.cz>
Diffstat (limited to 'btrfs-zero-log.c')
-rw-r--r--btrfs-zero-log.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/btrfs-zero-log.c b/btrfs-zero-log.c
index 1ea867b..f249aec 100644
--- a/btrfs-zero-log.c
+++ b/btrfs-zero-log.c
@@ -64,8 +64,8 @@ int main(int ac, char **av)
return 1;
trans = btrfs_start_transaction(root, 1);
- btrfs_set_super_log_root(&root->fs_info->super_copy, 0);
- btrfs_set_super_log_root_level(&root->fs_info->super_copy, 0);
+ btrfs_set_super_log_root(root->fs_info->super_copy, 0);
+ btrfs_set_super_log_root_level(root->fs_info->super_copy, 0);
btrfs_commit_transaction(trans, root);
close_ctree(root);
return ret;