mirror of
https://github.com/samba-team/samba.git
synced 2025-05-30 01:05:50 +03:00
s4 now supports the large readx extension
This commit is contained in:
parent
15a6a93d35
commit
8bba340e65
@ -499,8 +499,9 @@ static bool test_readx(struct torture_context *tctx, struct smbcli_state *cli)
|
|||||||
CHECK_STATUS(status, NT_STATUS_OK);
|
CHECK_STATUS(status, NT_STATUS_OK);
|
||||||
CHECK_VALUE(io.readx.out.remaining, 0xFFFF);
|
CHECK_VALUE(io.readx.out.remaining, 0xFFFF);
|
||||||
CHECK_VALUE(io.readx.out.compaction_mode, 0);
|
CHECK_VALUE(io.readx.out.compaction_mode, 0);
|
||||||
if (torture_setting_bool(tctx, "samba3", false)) {
|
if (torture_setting_bool(tctx, "samba3", false) ||
|
||||||
printf("SAMBA3: large read extension\n");
|
torture_setting_bool(tctx, "samba4", false)) {
|
||||||
|
printf("SAMBA: large read extension\n");
|
||||||
CHECK_VALUE(io.readx.out.nread, 80000);
|
CHECK_VALUE(io.readx.out.nread, 80000);
|
||||||
} else {
|
} else {
|
||||||
CHECK_VALUE(io.readx.out.nread, 0);
|
CHECK_VALUE(io.readx.out.nread, 0);
|
||||||
@ -543,8 +544,9 @@ static bool test_readx(struct torture_context *tctx, struct smbcli_state *cli)
|
|||||||
io.readx.in.maxcnt = 0x10000;
|
io.readx.in.maxcnt = 0x10000;
|
||||||
status = smb_raw_read(cli->tree, &io);
|
status = smb_raw_read(cli->tree, &io);
|
||||||
CHECK_STATUS(status, NT_STATUS_OK);
|
CHECK_STATUS(status, NT_STATUS_OK);
|
||||||
if (torture_setting_bool(tctx, "samba3", false)) {
|
if (torture_setting_bool(tctx, "samba3", false) ||
|
||||||
printf("SAMBA3: large read extension\n");
|
torture_setting_bool(tctx, "samba4", false)) {
|
||||||
|
printf("SAMBA: large read extension\n");
|
||||||
CHECK_VALUE(io.readx.out.nread, 0x10000);
|
CHECK_VALUE(io.readx.out.nread, 0x10000);
|
||||||
} else {
|
} else {
|
||||||
CHECK_VALUE(io.readx.out.nread, 0);
|
CHECK_VALUE(io.readx.out.nread, 0);
|
||||||
@ -553,12 +555,15 @@ static bool test_readx(struct torture_context *tctx, struct smbcli_state *cli)
|
|||||||
io.readx.in.maxcnt = 0x10001;
|
io.readx.in.maxcnt = 0x10001;
|
||||||
status = smb_raw_read(cli->tree, &io);
|
status = smb_raw_read(cli->tree, &io);
|
||||||
CHECK_STATUS(status, NT_STATUS_OK);
|
CHECK_STATUS(status, NT_STATUS_OK);
|
||||||
if (torture_setting_bool(tctx, "samba3", false)) {
|
if (torture_setting_bool(tctx, "samba3", false) ||
|
||||||
printf("SAMBA3: large read extension\n");
|
torture_setting_bool(tctx, "samba4", false)) {
|
||||||
|
printf("SAMBA: large read extension\n");
|
||||||
CHECK_VALUE(io.readx.out.nread, 0x10001);
|
CHECK_VALUE(io.readx.out.nread, 0x10001);
|
||||||
} else {
|
} else {
|
||||||
CHECK_VALUE(io.readx.out.nread, 0);
|
CHECK_VALUE(io.readx.out.nread, 0);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
printf("Server does not support the CAP_LARGE_READX extension\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
printf("Trying locked region\n");
|
printf("Trying locked region\n");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user