1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

r3249: - change_time is closer to ctime than mtime

- pvfs now passes the RAW-CLOSE test
(This used to be commit 98aea91ce6)
This commit is contained in:
Andrew Tridgell 2004-10-26 07:11:49 +00:00 committed by Gerald (Jerry) Carter
parent 7a11723cfc
commit f1814e5a53
3 changed files with 9 additions and 5 deletions

View File

@ -84,13 +84,13 @@ NTSTATUS pvfs_fill_dos_info(struct pvfs_state *pvfs, struct pvfs_filename *name)
/* for now just use the simple samba mapping */
unix_to_nt_time(&name->dos.create_time, name->st.st_ctime);
unix_to_nt_time(&name->dos.access_time, name->st.st_atime);
unix_to_nt_time(&name->dos.write_time, name->st.st_mtime);
unix_to_nt_time(&name->dos.change_time, name->st.st_mtime);
unix_to_nt_time(&name->dos.write_time, name->st.st_mtime);
unix_to_nt_time(&name->dos.change_time, name->st.st_ctime);
#ifdef HAVE_STAT_TV_NSEC
name->dos.create_time += name->st.st_ctim.tv_nsec / 100;
name->dos.access_time += name->st.st_atim.tv_nsec / 100;
name->dos.write_time += name->st.st_mtim.tv_nsec / 100;
name->dos.change_time += name->st.st_mtim.tv_nsec / 100;
name->dos.change_time += name->st.st_ctim.tv_nsec / 100;
#endif
name->dos.attrib = dos_mode_from_stat(pvfs, &name->st);
name->dos.alloc_size = name->st.st_size;

View File

@ -634,6 +634,10 @@ NTSTATUS pvfs_close(struct ntvfs_module_context *ntvfs,
NTSTATUS status;
struct utimbuf unix_times;
if (io->generic.level == RAW_CLOSE_SPLCLOSE) {
return NT_STATUS_UNSUCCESSFUL;
}
if (io->generic.level != RAW_CLOSE_CLOSE) {
return ntvfs_map_close(req, io, ntvfs);
}

View File

@ -37,12 +37,12 @@ tests="$tests BASE-DELETE BASE-PROPERTIES BASE-MANGLE"
tests="$tests BASE-CHKPATH BASE-SECLEAK"
tests="$tests RAW-QFSINFO RAW-QFILEINFO RAW-SFILEINFO-BUG"
tests="$tests RAW-LOCK RAW-MKDIR RAW-SEEK RAW-CONTEXT BASE-RENAME"
tests="$tests RAW-UNLINK RAW-READ"
tests="$tests RAW-UNLINK RAW-READ RAW-CLOSE"
tests="$tests LOCAL-ICONV LOCAL-TALLOC LOCAL-MESSAGING LOCAL-BINDING LOCAL-IDTREE"
soon="BASE-DENY1 BASE-DEFER_OPEN BASE-OPENATTR BASE-CHARSET"
soon="$soon RAW-SFILEINFO RAW-SEARCH RAW-OPEN RAW-OPLOCK RAW-NOTIFY RAW-MUX RAW-IOCTL"
soon="$soon RAW-CHKPATH RAW-WRITE RAW-RENAME RAW-CLOSE BASE-TRANS2"
soon="$soon RAW-CHKPATH RAW-WRITE RAW-RENAME BASE-TRANS2"
soon="$soon BASE-TRANS2"
for t in $tests; do