summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/file_access.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/smbd/file_access.c b/source3/smbd/file_access.c
index 46472665e5..a58bcdd891 100644
--- a/source3/smbd/file_access.c
+++ b/source3/smbd/file_access.c
@@ -76,12 +76,14 @@ static NTSTATUS conn_get_nt_acl(TALLOC_CTX *mem_ctx,
&secdesc);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(5, ("Unable to get NT ACL for file %s\n", fname));
- return status;
+ goto done;
}
*psd = talloc_move(mem_ctx, &secdesc);
+
+done:
close_file(fsp, NORMAL_CLOSE);
- return NT_STATUS_OK;
+ return status;
}
static bool can_access_file_acl(struct connection_struct *conn,