diff options
author | Jeremy Allison <jra@samba.org> | 2000-10-06 03:21:49 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2000-10-06 03:21:49 +0000 |
commit | 636f146abf0a75cd3b21a57b50627ee149a635ab (patch) | |
tree | 923f7449e67e10c738e388174d3d36124636c44f /source3/smbd/unix_acls.c | |
parent | 56d514235ed16d3cb6b3682afa6980eb3455c50d (diff) | |
download | samba-636f146abf0a75cd3b21a57b50627ee149a635ab.tar.gz samba-636f146abf0a75cd3b21a57b50627ee149a635ab.tar.bz2 samba-636f146abf0a75cd3b21a57b50627ee149a635ab.zip |
Restructuring of vfs layer to include a "this" pointer - can be an fsp or
a conn struct depending on the call.
We need this to have a clean NT ACL call interface.
This will break any existing VFS libraries (that's why this is pre-release
code).
Andrew gets credit for this one :-) :-).
In addition - added Herb's WITH_PROFILE changes - Herb - please examine
the changes I've made to the smbd/reply.c code you added. The original
code was very ugly and I have replaced it with a
START_PROFILE(x)/END_PROFILE(x) pair using the preprocessor.
Please check this compiles ok with the --with-profile switch.
Jeremy.
(This used to be commit b07611f8159b0b3f42e7e02611be9f4d56de96f5)
Diffstat (limited to 'source3/smbd/unix_acls.c')
-rw-r--r-- | source3/smbd/unix_acls.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/source3/smbd/unix_acls.c b/source3/smbd/unix_acls.c index a564ec9ee5..d32f1cfaae 100644 --- a/source3/smbd/unix_acls.c +++ b/source3/smbd/unix_acls.c @@ -357,16 +357,16 @@ size_t get_nt_acl(files_struct *fsp, SEC_DESC **ppdesc) */ if ((fsp->is_directory || fsp->fd == -1) && fsp->conn->vfs_ops.get_nt_acl) - return fsp->conn->vfs_ops.get_nt_acl(dos_to_unix(fsp->fsp_name, False), ppdesc); + return fsp->conn->vfs_ops.get_nt_acl(fsp->conn,dos_to_unix(fsp->fsp_name, False), ppdesc); else if (fsp->conn->vfs_ops.fget_nt_acl) - return fsp->conn->vfs_ops.fget_nt_acl(fsp->fd, ppdesc); + return fsp->conn->vfs_ops.fget_nt_acl(fsp,fsp->fd, ppdesc); if(fsp->is_directory || fsp->fd == -1) { if(vfs_stat(fsp->conn,fsp->fsp_name, &sbuf) != 0) { return 0; } } else { - if(fsp->conn->vfs_ops.fstat(fsp->fd,&sbuf) != 0) { + if(fsp->conn->vfs_ops.fstat(fsp,fsp->fd,&sbuf) != 0) { return 0; } } @@ -467,9 +467,9 @@ BOOL set_nt_acl(files_struct *fsp, uint32 security_info_sent, SEC_DESC *psd) */ if ((fsp->is_directory || fsp->fd == -1) && fsp->conn->vfs_ops.set_nt_acl) - return fsp->conn->vfs_ops.set_nt_acl(dos_to_unix(fsp->fsp_name, False), security_info_sent, psd); + return fsp->conn->vfs_ops.set_nt_acl(conn,dos_to_unix(fsp->fsp_name, False), security_info_sent, psd); else if (fsp->conn->vfs_ops.fset_nt_acl) - return fsp->conn->vfs_ops.fset_nt_acl(fsp->fd, security_info_sent, psd); + return fsp->conn->vfs_ops.fset_nt_acl(fsp,fsp->fd, security_info_sent, psd); /* * Get the current state of the file. @@ -479,7 +479,7 @@ BOOL set_nt_acl(files_struct *fsp, uint32 security_info_sent, SEC_DESC *psd) if(vfs_stat(fsp->conn,fsp->fsp_name, &sbuf) != 0) return False; } else { - if(conn->vfs_ops.fstat(fsp->fd,&sbuf) != 0) + if(conn->vfs_ops.fstat(fsp,fsp->fd,&sbuf) != 0) return False; } @@ -524,7 +524,7 @@ BOOL set_nt_acl(files_struct *fsp, uint32 security_info_sent, SEC_DESC *psd) if(fsp->fd == -1) ret = vfs_stat(fsp->conn, fsp->fsp_name, &sbuf); else - ret = conn->vfs_ops.fstat(fsp->fd,&sbuf); + ret = conn->vfs_ops.fstat(fsp,fsp->fd,&sbuf); if(ret != 0) return False; @@ -570,7 +570,7 @@ BOOL set_nt_acl(files_struct *fsp, uint32 security_info_sent, SEC_DESC *psd) DEBUG(3,("call_nt_transact_set_security_desc: chmod %s. perms = 0%o.\n", fsp->fsp_name, (unsigned int)perms )); - if(conn->vfs_ops.chmod(dos_to_unix(fsp->fsp_name, False), perms) == -1) { + if(conn->vfs_ops.chmod(conn,dos_to_unix(fsp->fsp_name, False), perms) == -1) { DEBUG(3,("call_nt_transact_set_security_desc: chmod %s, 0%o failed. Error = %s.\n", fsp->fsp_name, (unsigned int)perms, strerror(errno) )); return False; |