summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2006-06-22 17:33:56 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:09:29 -0500
commit70eac2a274063c76a3f0fa9504d2a1c30ee4b494 (patch)
tree1b3c6c20fd4351f9488a36a74f798da707a518c4 /source4
parent7bf085571eba5f321d35ff449d68da39ec303dab (diff)
downloadsamba-70eac2a274063c76a3f0fa9504d2a1c30ee4b494.tar.gz
samba-70eac2a274063c76a3f0fa9504d2a1c30ee4b494.tar.bz2
samba-70eac2a274063c76a3f0fa9504d2a1c30ee4b494.zip
r16466: for SMB2_ALL_EAS it's not valid for the ntvfs backends to return
0 eas, they should return an error: NO_EAS_ON_FILE or NO_MORE_EAS metze (This used to be commit fdefec1de99273978345d4a183a9660bd741e045)
Diffstat (limited to 'source4')
-rw-r--r--source4/smb_server/blob.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/source4/smb_server/blob.c b/source4/smb_server/blob.c
index d62067cdfd..6e798035a2 100644
--- a/source4/smb_server/blob.c
+++ b/source4/smb_server/blob.c
@@ -444,6 +444,15 @@ NTSTATUS smbsrv_push_passthru_fileinfo(TALLOC_CTX *mem_ctx,
return NT_STATUS_OK;
case RAW_FILEINFO_SMB2_ALL_EAS:
+ /* if no eas are returned the backend should
+ * have returned NO_EAS_ON_FILE or NO_MORE_EAS
+ *
+ * so it's a programmer error if num_eas == 0
+ */
+ if (st->all_eas.out.num_eas == 0) {
+ smb_panic("0 eas for SMB2_ALL_EAS - programmer error in ntvfs backend");
+ }
+
list_size = ea_list_size_chained(st->all_eas.out.num_eas,
st->all_eas.out.eas);
BLOB_CHECK(smbsrv_blob_grow_data(mem_ctx, blob, list_size));