summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/smbd/pysmbd.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source3/smbd/pysmbd.c b/source3/smbd/pysmbd.c
index cfc4012630..9de26291d2 100644
--- a/source3/smbd/pysmbd.c
+++ b/source3/smbd/pysmbd.c
@@ -101,6 +101,9 @@ static NTSTATUS set_nt_acl_no_snum(const char *fname,
set_conn_connectpath(conn, "/");
smbd_vfs_init(conn);
+ if (!posix_locking_init(false)) {
+ return NT_STATUS_NO_MEMORY;
+ }
fsp = talloc_zero(frame, struct files_struct);
if (fsp == NULL) {
@@ -145,6 +148,8 @@ static NTSTATUS set_nt_acl_no_snum(const char *fname,
DEBUG(0,("set_nt_acl_no_snum: fset_nt_acl returned %s.\n", nt_errstr(status)));
}
+ SMB_VFS_CLOSE(fsp);
+
conn_free(conn);
TALLOC_FREE(frame);