summaryrefslogtreecommitdiff
path: root/source3/smbd/close.c
diff options
context:
space:
mode:
authorTim Prouty <tprouty@samba.org>2009-06-22 15:26:56 -0700
committerTim Prouty <tprouty@samba.org>2009-06-24 21:15:25 -0700
commite129384d7c1df664e447186673dd107e190e2894 (patch)
tree166c08e9d2ee0bbb8a88fb2ad76ed226a62f83dc /source3/smbd/close.c
parent36c10191750c845a2a7cd6cc62149b1095c0b651 (diff)
downloadsamba-e129384d7c1df664e447186673dd107e190e2894.tar.gz
samba-e129384d7c1df664e447186673dd107e190e2894.tar.bz2
samba-e129384d7c1df664e447186673dd107e190e2894.zip
s3: Plumb smb_filename through SMB_VFS_STAT and SMB_VFS_LSTAT
This patch introduces two new temporary helper functions vfs_stat_smb_fname and vfs_lstat_smb_fname. They basically allowed me to call the new smb_filename version of stat, while avoiding plumbing it through callers that are still too inconvenient. As the conversion moves along, I will be able to remove callers of this, with the goal being to remove all callers. There was also a bug in create_synthetic_smb_fname_split (also a temporary utility function) that caused it to incorrectly handle filenames with ':'s in them when in posix mode. This is now fixed.
Diffstat (limited to 'source3/smbd/close.c')
-rw-r--r--source3/smbd/close.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/source3/smbd/close.c b/source3/smbd/close.c
index 760a2d520c..ad21cf1d40 100644
--- a/source3/smbd/close.c
+++ b/source3/smbd/close.c
@@ -377,9 +377,9 @@ static NTSTATUS close_remove_share_mode(files_struct *fsp,
hasn't been renamed. */
if (fsp->posix_open) {
- ret = SMB_VFS_LSTAT(conn,fsp->fsp_name,&sbuf);
+ ret = vfs_lstat_smb_fname(conn,fsp->fsp_name,&sbuf);
} else {
- ret = SMB_VFS_STAT(conn,fsp->fsp_name,&sbuf);
+ ret = vfs_stat_smb_fname(conn,fsp->fsp_name,&sbuf);
}
if (ret != 0) {
@@ -502,9 +502,11 @@ static NTSTATUS update_write_time_on_close(struct files_struct *fsp)
ret = SMB_VFS_FSTAT(fsp, &sbuf);
} else {
if (fsp->posix_open) {
- ret = SMB_VFS_LSTAT(fsp->conn,fsp->fsp_name,&sbuf);
+ ret = vfs_lstat_smb_fname(fsp->conn, fsp->fsp_name,
+ &sbuf);
} else {
- ret = SMB_VFS_STAT(fsp->conn,fsp->fsp_name,&sbuf);
+ ret = vfs_stat_smb_fname(fsp->conn, fsp->fsp_name,
+ &sbuf);
}
}