s3: VFS: Modify SMB_VFS_GET_NT_ACL to take a const struct smb_filename * instead...
[bbaumbach/samba-autobuild/.git] / source3 / smbd / pysmbd.c
index df8d0799929178d118af0272eb659c65b32b3dd0..cd6a1e2e72463fa58489ced1df00be80e1646243 100644 (file)
@@ -195,8 +195,22 @@ static NTSTATUS get_nt_acl_conn(TALLOC_CTX *mem_ctx,
                                struct security_descriptor **sd)
 {
        TALLOC_CTX *frame = talloc_stackframe();
-       NTSTATUS status = SMB_VFS_GET_NT_ACL( conn, fname, security_info_wanted,
-                                    mem_ctx, sd);
+       NTSTATUS status;
+       struct smb_filename *smb_fname = synthetic_smb_fname(talloc_tos(),
+                                               fname,
+                                               NULL,
+                                               NULL);
+
+       if (smb_fname == NULL) {
+               TALLOC_FREE(frame);
+               return NT_STATUS_NO_MEMORY;
+       }
+
+       status = SMB_VFS_GET_NT_ACL(conn,
+                               smb_fname,
+                               security_info_wanted,
+                               mem_ctx,
+                               sd);
        if (!NT_STATUS_IS_OK(status)) {
                DEBUG(0,("get_nt_acl_conn: get_nt_acl returned %s.\n", nt_errstr(status)));
        }