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

smbd: Convert smb_set_file_dosmode to synthetic_smb_fname

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
Volker Lendecke 2013-04-15 10:50:53 +02:00 committed by Jeremy Allison
parent edb7293020
commit 381bd97f13

View File

@ -5721,7 +5721,7 @@ static NTSTATUS smb_set_file_dosmode(connection_struct *conn,
const struct smb_filename *smb_fname,
uint32 dosmode)
{
struct smb_filename *smb_fname_base = NULL;
struct smb_filename *smb_fname_base;
NTSTATUS status;
if (!VALID_STAT(smb_fname->st)) {
@ -5729,11 +5729,10 @@ static NTSTATUS smb_set_file_dosmode(connection_struct *conn,
}
/* Always operate on the base_name, even if a stream was passed in. */
status = create_synthetic_smb_fname(talloc_tos(), smb_fname->base_name,
NULL, &smb_fname->st,
&smb_fname_base);
if (!NT_STATUS_IS_OK(status)) {
return status;
smb_fname_base = synthetic_smb_fname(
talloc_tos(), smb_fname->base_name, NULL, &smb_fname->st);
if (smb_fname_base == NULL) {
return NT_STATUS_NO_MEMORY;
}
if (dosmode) {