From 2eea03c4540ea3c14927333f2e244ce5f4587d47 Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Tue, 26 Mar 2013 16:37:22 -0700 Subject: [PATCH] Fix bug #9130 - Certain xattrs cause Windows error 0x800700FF Ensure we never return any zero-length EA's. Signed-off-by: Jeremy Allison Reviewed-by: David Disseldorp --- source3/smbd/trans2.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index e9ff3216f10..325f2637e68 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -357,6 +357,15 @@ static NTSTATUS get_ea_list_from_file_path(TALLOC_CTX *mem_ctx, connection_struc return status; } + if (listp->ea.value.length == 0) { + /* + * We can never return a zero length EA. + * Windows reports the EA's as corrupted. + */ + TALLOC_FREE(listp); + continue; + } + push_ascii_fstring(dos_ea_name, listp->ea.name); *pea_total_len += -- 2.11.4.GIT