]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4: torture: Fix raw.search:test_one_file() by using the SMB1+POSIX connection for...
authorJeremy Allison <jra@samba.org>
Fri, 19 Nov 2021 22:51:39 +0000 (14:51 -0800)
committerRalph Boehme <slow@samba.org>
Sat, 11 Dec 2021 11:14:31 +0000 (11:14 +0000)
Remove the following entry in knownfail.d/posix_infolevel_fails.

^samba3.raw.search.one\ file\ search.*

from knownfail.d/posix_infolevel_fails

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
selftest/knownfail.d/posix_infolevel_fails
source4/torture/raw/search.c

index 78a6781684ced7923730d3877a89e8b01432af05..4ce4a9cec9101e3df48af88394457a10186f95a8 100644 (file)
@@ -5,4 +5,3 @@
 ^samba3.blackbox.inherit_owner.*.NT1.*verify.*unix\ owner.*
 ^samba3.unix.info2.info2\(nt4_dc_smb1\)
 ^samba3.unix.info2.info2\(ad_dc_smb1\)
-^samba3.raw.search.one\ file\ search.*
index 3f7de80ad0f82be9d4f122daffbc354d05d16a61..575bbd03fb7785fa215d2e49af3a15e76c7824f2 100644 (file)
@@ -389,10 +389,19 @@ static bool test_one_file(struct torture_context *tctx,
        for (i=0;i<ARRAY_SIZE(levels);i++) {
                NTSTATUS expected_status;
                uint32_t cap = cli->transport->negotiate.capabilities;
+               struct smbcli_state *cli_search = cli;
 
                torture_comment(tctx, "Testing %s\n", levels[i].name);
 
-               levels[i].status = torture_single_search(cli, tctx, fname, 
+               if (levels[i].data_level == RAW_SEARCH_DATA_UNIX_INFO) {
+                       /*
+                        * For an SMB1+POSIX info level, use the cli_unix
+                        * connection.
+                        */
+                       cli_search = cli_unix;
+               }
+
+               levels[i].status = torture_single_search(cli_search, tctx, fname,
                                                         levels[i].level,
                                                         levels[i].data_level,
                                                         0,
@@ -416,7 +425,7 @@ static bool test_one_file(struct torture_context *tctx,
                        continue;
                }
 
-               status = torture_single_search(cli, tctx, fname2, 
+               status = torture_single_search(cli_search, tctx, fname2,
                                               levels[i].level,
                                               levels[i].data_level,
                                               0,