]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: smbd: SMB1 reply_search(). The dptr already knows if the mask has a wildcard.
authorJeremy Allison <jra@samba.org>
Tue, 29 Sep 2020 19:05:53 +0000 (12:05 -0700)
committerRalph Boehme <slow@samba.org>
Wed, 30 Sep 2020 20:46:40 +0000 (20:46 +0000)
Get the value from the dptr instead.

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/smbd/reply.c

index 25154f4efde53886216d64941f2009d7fb9c51d4..e848d6c553cdbd376a3805193d41ac32a4169b04 100644 (file)
@@ -2014,16 +2014,11 @@ void reply_search(struct smb_request *req)
                if (!mask) {
                        goto SearchEmpty;
                }
-               /*
-                * For a 'continue' search we have no string. So
-                * check from the initial saved string.
-                */
-               if (!req->posix_pathnames) {
-                       mask_contains_wcard = ms_has_wild(mask);
-               }
                dirtype = dptr_attr(sconn, dptr_num);
        }
 
+       mask_contains_wcard = dptr_has_wild(fsp->dptr);
+
        DEBUG(4,("dptr_num is %d\n",dptr_num));
 
        if ((dirtype&0x1F) == FILE_ATTRIBUTE_VOLUME) {