mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
r3372: fixed the initial directory permissions for pvfs_mkdir()
(This used to be commit 72ddb38a72
)
This commit is contained in:
parent
b17470a80d
commit
b97145b2a6
@ -32,6 +32,7 @@ NTSTATUS pvfs_mkdir(struct ntvfs_module_context *ntvfs,
|
||||
struct pvfs_state *pvfs = ntvfs->private_data;
|
||||
NTSTATUS status;
|
||||
struct pvfs_filename *name;
|
||||
mode_t mode;
|
||||
|
||||
if (md->generic.level != RAW_MKDIR_MKDIR) {
|
||||
return NT_STATUS_INVALID_LEVEL;
|
||||
@ -48,10 +49,9 @@ NTSTATUS pvfs_mkdir(struct ntvfs_module_context *ntvfs,
|
||||
return NT_STATUS_OBJECT_NAME_COLLISION;
|
||||
}
|
||||
|
||||
/* TODO: this is a temporary implementation to allow other
|
||||
tests to run */
|
||||
mode = pvfs_fileperms(pvfs, FILE_ATTRIBUTE_DIRECTORY);
|
||||
|
||||
if (mkdir(name->full_name, 0777) == -1) {
|
||||
if (mkdir(name->full_name, mode) == -1) {
|
||||
return pvfs_map_errno(pvfs, errno);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user