smbd: implement the strange write time update logic
commit2eab212ea2e1bfd8fa716c2c89b2c042f7ba12ea
authorStefan Metzmacher <metze@samba.org>
Wed, 12 Mar 2008 14:39:38 +0000 (12 15:39 +0100)
committerStefan Metzmacher <metze@samba.org>
Mon, 7 Apr 2008 10:29:26 +0000 (7 12:29 +0200)
tree67cca7afe9765823d428fdc7ac93042b9fd44f54
parent6aaa2ce0eeb46f6735ec984a2e7aadde7a7f456d
smbd: implement the strange write time update logic

We now never call file_ntimes() directly, every update
is done via smb_set_file_time().

This let samba3 pass the BASE-DELAYWRITE test.

The write time is only updated 2 seconds after the
first write() on any open handle to the current time
(not the time of the first write).

Each handle which had write requests updates the write
time to the current time on close().

If the write time is set explicit via setfileinfo or setpathinfo
the write time is visible directly and a following close
on the same handle doesn't update the write time.

metze
source/include/smb.h
source/smbd/close.c
source/smbd/dir.c
source/smbd/dosmode.c
source/smbd/fileio.c
source/smbd/files.c
source/smbd/nttrans.c
source/smbd/reply.c
source/smbd/trans2.c