summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2013-03-29 10:07:20 -0700
committerDavid Disseldorp <ddiss@samba.org>2013-04-02 20:06:37 +0200
commit1e8bcce52f233722fad5c25f2467b86d97cadfa0 (patch)
tree99a5045c8f7a1fe925dd446e8790a0d4cd914df3 /source3
parent50e0060091e008ad93fcfbb68cbbb81da5dec067 (diff)
downloadsamba-1e8bcce52f233722fad5c25f2467b86d97cadfa0.tar.gz
samba-1e8bcce52f233722fad5c25f2467b86d97cadfa0.tar.bz2
samba-1e8bcce52f233722fad5c25f2467b86d97cadfa0.zip
Ensure we can never return an uninitialized EA list.
Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: David Disseldorp <ddiss@suse.de>
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/trans2.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c
index fae9e1ff9d..ee16bf9b53 100644
--- a/source3/smbd/trans2.c
+++ b/source3/smbd/trans2.c
@@ -323,6 +323,7 @@ static NTSTATUS get_ea_list_from_file_path(TALLOC_CTX *mem_ctx, connection_struc
NTSTATUS status;
*pea_total_len = 0;
+ *ea_list = NULL;
status = get_ea_names_from_file(talloc_tos(), conn, fsp, fname,
&names, &num_names);
@@ -516,7 +517,7 @@ static unsigned int estimate_ea_size(connection_struct *conn, files_struct *fsp,
{
size_t total_ea_len = 0;
TALLOC_CTX *mem_ctx;
- struct ea_list *ea_list;
+ struct ea_list *ea_list = NULL;
if (!lp_ea_support(SNUM(conn))) {
return 0;