btrfs: test cloning of zero length ranges
authorFilipe Manana <fdmanana@suse.com>
Wed, 1 Apr 2015 00:39:24 +0000 (11:39 +1100)
committerDave Chinner <david@fromorbit.com>
Wed, 1 Apr 2015 00:39:24 +0000 (11:39 +1100)
commit9edaf22811c2cee3ebeb87cfc1bc28018c7f067b
tree0a655431ae70264ca2c20e552954b5719220689f
parentb2aa857e0a9286f448f0523850b225686a6a4ec6
btrfs: test cloning of zero length ranges

Test cloning a file range with a length of zero into a destination offset
greater than zero.

This made btrfs create an extent state record with a start offset greater than
the end offset, resulting in chaos such as an infinite loop when evicting an
inode.

This issue was fixed by the following linux kernel patch:

   Btrfs: fix inode eviction infinite loop after cloning into it

Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Dave Chinner <david@fromorbit.com>
tests/btrfs/086 [new file with mode: 0755]
tests/btrfs/086.out [new file with mode: 0644]
tests/btrfs/group