mirror of
https://github.com/linux-apfs/apfstests.git
synced 2026-05-01 15:01:44 -07:00
generic/159, 160: deal with EACCES -> EPERM transition
As of 4.8 we can receive EPERM (instead of EACCES) for attempts to reflink/dedupe to an immutable file. Fix this up so that we accept either answer. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Eryu Guan <eguan@redhat.com> Signed-off-by: Eryu Guan <eguan@redhat.com>
This commit is contained in:
committed by
Eryu Guan
parent
acede2049a
commit
297985bfeb
+6
-1
@@ -65,9 +65,14 @@ _pwrite_byte 0x61 0 $sz $testdir1/file1 >> $seqres.full
|
||||
_pwrite_byte 0x61 0 $sz $testdir1/file2 >> $seqres.full
|
||||
sync
|
||||
|
||||
do_filter_output()
|
||||
{
|
||||
_filter_test_dir | sed -e 's/Operation not permitted/Permission denied/g'
|
||||
}
|
||||
|
||||
echo "Try dedupe on immutable files"
|
||||
$CHATTR_PROG +i $testdir1/file1 $testdir1/file2
|
||||
_dedupe_range $testdir1/file1 0 $testdir1/file2 0 $blksz 2>&1 | _filter_test_dir
|
||||
_dedupe_range $testdir1/file1 0 $testdir1/file2 0 $blksz 2>&1 | do_filter_output
|
||||
$CHATTR_PROG -i $testdir1/file1 $testdir1/file2
|
||||
|
||||
# success, all done
|
||||
|
||||
Reference in New Issue
Block a user