]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commit
libxfs: ensure btree root split sets blkno correctly
authorDave Chinner <dchinner@redhat.com>
Wed, 4 Sep 2013 22:05:09 +0000 (22:05 +0000)
committerRich Johnston <rjohnston@sgi.com>
Mon, 16 Sep 2013 20:14:40 +0000 (15:14 -0500)
commit77ec5ff42e18b24119a4848001a1f3e50725bdfd
tree7a10e582a4fea1f1f08eb132f3ff7f363485b17e
parent84796a146ce8b711ba596303e41002dc7720c976
libxfs: ensure btree root split sets blkno correctly

For CRC enabled filesystems, the BMBT is rooted in an inode, so it
passes through a difference code path on root splits to the
freespace and inode btrees. The inode based btree root has a
corruption problem on split - it's the same problem we saw in the
directory/attr code where headers are memcpy()d from one block to
another without updating the self describing metadata.

Simple fix - when copying the header out of the root block, make
sure the block number is updated correctly.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Review-by: Mark Tinguely <tinguely@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
libxfs/xfs_btree.c