From 77f739f03a32965b676d97a6f082bb3e023014ef Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Wed, 12 Oct 2011 18:34:26 +0200 Subject: s4:torture/smb2: we only support 64KB reads/writes for now We don't have multi-credit support yet. metze --- source4/torture/smb2/connect.c | 12 ++++++------ source4/torture/smb2/read.c | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'source4/torture/smb2') diff --git a/source4/torture/smb2/connect.c b/source4/torture/smb2/connect.c index 1b69c18a55..b383a67a44 100644 --- a/source4/torture/smb2/connect.c +++ b/source4/torture/smb2/connect.c @@ -71,14 +71,14 @@ static NTSTATUS torture_smb2_write(struct torture_context *tctx, struct smb2_tre NTSTATUS status; DATA_BLOB data; int i; + uint32_t size = torture_setting_int(tctx, "smb2maxwrite", 64*1024); - if (torture_setting_bool(tctx, "dangerous", false)) { - data = data_blob_talloc(tree, NULL, 160000); - } else if (torture_setting_bool(tctx, "samba4", false)) { - data = data_blob_talloc(tree, NULL, UINT16_MAX); - } else { - data = data_blob_talloc(tree, NULL, torture_setting_int(tctx, "smb2maxwrite", 120000)); + data = data_blob_talloc(tree, NULL, size); + if (size != data.length) { + printf("data_blob_talloc(%s) failed\n", size); + return NT_STATUS_NO_MEMORY; } + for (i=0;i