]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
Fix bug creating files using DOS clients with mixed
authorJeremy Allison <jra@samba.org>
Fri, 25 Jul 2008 20:16:18 +0000 (13:16 -0700)
committerJeremy Allison <jra@samba.org>
Fri, 25 Jul 2008 20:16:18 +0000 (13:16 -0700)
case files. Reported by Daniel Johnson <Progman2000@usa.net>.
The smb_set_file_time() call to set the filetimes is failing
because it's using the unmodified name passed in by the
client, not the modified name (matching case on the
disk) that comes out from create_file().
Jeremy.

source/smbd/reply.c

index ee646aa7c3a4c4f4d8afb59c8375e42d58028942..ddc5dd06a541a88b3630b4fa1221ff410fba03aa 100644 (file)
@@ -2030,7 +2030,7 @@ void reply_mknew(struct smb_request *req)
        }
 
        ts[0] = get_atimespec(&sbuf); /* atime. */
-       status = smb_set_file_time(conn, fsp, fname, &sbuf, ts, true);
+       status = smb_set_file_time(conn, fsp, fsp->fsp_name, &sbuf, ts, true);
        if (!NT_STATUS_IS_OK(status)) {
                END_PROFILE(SMBcreate);
                reply_openerror(req, status);