git.samba.org
/
kai
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ed43a5a
)
Based on code from Richard Sharpe <realrichardsharpe@gmail.com>,
author
Jeremy Allison
<jra@samba.org>
Wed, 28 Mar 2012 22:09:47 +0000
(15:09 -0700)
committer
Jeremy Allison
<jra@samba.org>
Thu, 29 Mar 2012 15:53:43 +0000
(08:53 -0700)
ensure we don't crash on a NULL DACL.
source3/smbd/file_access.c
patch
|
blob
|
history
diff --git
a/source3/smbd/file_access.c
b/source3/smbd/file_access.c
index 9fff8e3051fdc39cd156f87fbceb5ad9006d48a7..6ced6a625587798ffdadb1d92b75a1d88048e679 100644
(file)
--- a/
source3/smbd/file_access.c
+++ b/
source3/smbd/file_access.c
@@
-155,7
+155,10
@@
bool directory_has_default_acl(connection_struct *conn, const char *fname)
NTSTATUS status = SMB_VFS_GET_NT_ACL(conn, fname,
SECINFO_DACL, &secdesc);
- if (!NT_STATUS_IS_OK(status) || secdesc == NULL) {
+ if (!NT_STATUS_IS_OK(status) ||
+ secdesc == NULL ||
+ secdesc->dacl == NULL) {
+ TALLOC_FREE(secdesc);
return false;
}