]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbtorture: remove more allocation size checks
authorRalph Boehme <slow@samba.org>
Fri, 8 Nov 2024 12:09:15 +0000 (13:09 +0100)
committerAnoop C S <anoopcs@samba.org>
Mon, 11 Nov 2024 12:53:05 +0000 (12:53 +0000)
If the requested allocation size was 0, the resulting allocation size may be
larger due to xattrs and other filesystem dependent factors.

Cf commits fba4b290856faaf17305103efc65f6383ea4f61c and
55b2f247f9ba56516efba52481418966a777343e.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Anoop C S <anoopcs@samba.org>
source4/torture/raw/open.c

index f4eeb4e8c6e4af8495b282018a8f8e8378ed1fc9..69b698d5ea0c8cd81c244de2030f029d82df952b 100644 (file)
@@ -835,7 +835,6 @@ static bool test_ntcreatex(struct torture_context *tctx, struct smbcli_state *cl
        CHECK_ALL_INFO(io.ntcreatex.out.attrib, attrib);
        CHECK_VAL(io.ntcreatex.out.attrib & ~FILE_ATTRIBUTE_NONINDEXED,
                  FILE_ATTRIBUTE_DIRECTORY);
-       CHECK_ALL_INFO(io.ntcreatex.out.alloc_size, alloc_size);
        CHECK_ALL_INFO(io.ntcreatex.out.size, size);
        CHECK_ALL_INFO(io.ntcreatex.out.is_directory, directory);
        CHECK_VAL(io.ntcreatex.out.is_directory, 1);
@@ -1107,7 +1106,6 @@ static bool test_nttrans_create(struct torture_context *tctx, struct smbcli_stat
        CHECK_ALL_INFO(io.ntcreatex.out.attrib, attrib);
        CHECK_VAL(io.ntcreatex.out.attrib & ~FILE_ATTRIBUTE_NONINDEXED,
                  FILE_ATTRIBUTE_DIRECTORY);
-       CHECK_ALL_INFO(io.ntcreatex.out.alloc_size, alloc_size);
        CHECK_ALL_INFO(io.ntcreatex.out.size, size);
        CHECK_ALL_INFO(io.ntcreatex.out.is_directory, directory);
        CHECK_VAL(io.ntcreatex.out.is_directory, 1);
@@ -2161,7 +2159,6 @@ static bool test_ntcreatex_supersede(struct torture_context *tctx, struct smbcli
        CHECK_NTTIME(io.ntcreatex.out.write_time, write_time);
        CHECK_NTTIME(io.ntcreatex.out.change_time, change_time);
        CHECK_ALL_INFO(io.ntcreatex.out.attrib, attrib);
-       CHECK_ALL_INFO(io.ntcreatex.out.alloc_size, alloc_size);
        CHECK_ALL_INFO(io.ntcreatex.out.size, size);
        CHECK_ALL_INFO(io.ntcreatex.out.is_directory, directory);
        CHECK_VAL(io.ntcreatex.out.file_type, FILE_TYPE_DISK);
@@ -2189,7 +2186,6 @@ static bool test_ntcreatex_supersede(struct torture_context *tctx, struct smbcli
        CHECK_NTTIME(io.ntcreatex.out.write_time, write_time);
        CHECK_NTTIME(io.ntcreatex.out.change_time, change_time);
        CHECK_ALL_INFO(io.ntcreatex.out.attrib, attrib);
-       CHECK_ALL_INFO(io.ntcreatex.out.alloc_size, alloc_size);
        CHECK_VAL(io.ntcreatex.out.size, 512);
        CHECK_ALL_INFO(io.ntcreatex.out.is_directory, directory);
        CHECK_VAL(io.ntcreatex.out.file_type, FILE_TYPE_DISK);
@@ -2213,7 +2209,6 @@ static bool test_ntcreatex_supersede(struct torture_context *tctx, struct smbcli
        CHECK_NTTIME(io.ntcreatex.out.create_time, create_time);
        CHECK_NTTIME(io.ntcreatex.out.access_time, access_time);
        CHECK_ALL_INFO(io.ntcreatex.out.attrib, attrib);
-       CHECK_ALL_INFO(io.ntcreatex.out.alloc_size, alloc_size);
        CHECK_ALL_INFO(io.ntcreatex.out.is_directory, directory);
        CHECK_VAL(io.ntcreatex.out.file_type, FILE_TYPE_DISK);
 done: