From: Yan Zheng Date: Wed, 21 Jan 2009 15:49:16 +0000 (-0500) Subject: Btrfs: fix stop searching test in replace_one_extent X-Git-Tag: v2.6.29-rc4~9^2~20^2~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=86288a198d8e4e8411ff02f9ab848245e8f11257;p=pandora-kernel.git Btrfs: fix stop searching test in replace_one_extent replace_one_extent searches tree leaves for references to a given extent. It stops searching if it goes beyond the last possible position. The last possible position is computed by adding the starting offset of a found file extent to the full size of the extent. The code uses physical size of the extent as the full size. This is incorrect when compression is used. The fix is get the full size from ram_bytes field of file extent item. Signed-off-by: Yan Zheng --- Reading git-diff-tree failed