]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: use fdos_mode() in smb_set_file_dosmode()
authorRalph Boehme <slow@samba.org>
Mon, 19 Oct 2020 19:08:29 +0000 (21:08 +0200)
committerRalph Boehme <slow@samba.org>
Wed, 16 Dec 2020 09:08:32 +0000 (09:08 +0000)
Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/trans2.c

index 64b8f1711e106e5a099ed367957acc72df7343c5..41f991e4e3a28e43d1f56a3af47671145683dceb 100644 (file)
@@ -6665,7 +6665,7 @@ static NTSTATUS smb_set_file_dosmode(connection_struct *conn,
        DEBUG(6,("smb_set_file_dosmode: dosmode: 0x%x\n", (unsigned int)dosmode));
 
        /* check the mode isn't different, before changing it */
-       if ((dosmode != 0) && (dosmode != dos_mode(conn, smb_fname_base))) {
+       if ((dosmode != 0) && (dosmode != fdos_mode(fsp))) {
                DEBUG(10,("smb_set_file_dosmode: file %s : setting dos mode "
                          "0x%x\n", smb_fname_str_dbg(smb_fname_base),
                          (unsigned int)dosmode));