]> git.baikalelectronics.ru Git - kernel.git/commit
BTRFS: Fix lseek return value for error
authorJeff Liu <jeff.liu@oracle.com>
Sun, 18 Sep 2011 14:34:02 +0000 (10:34 -0400)
committerChris Mason <chris.mason@oracle.com>
Sun, 18 Sep 2011 14:34:02 +0000 (10:34 -0400)
commit79120b8ef363d40337998e17def9c9d1d5092cf6
treeee6da3e2edae6e355e6133dafd08d5323c136ac5
parentc2d9ba5c06cc53fcd77936073139f9fa9af59733
BTRFS: Fix lseek return value for error

The recent reworking of btrfs' lseek lead to incorrect
values being returned.  This adds checks for seeking
beyond EOF in SEEK_HOLE and makes sure the error
values come back correct.

Andi Kleen also sent in similar patches.

Signed-off-by: Jie Liu <jeff.liu@oracle.com>
Reported-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/file.c