From a33f57077686a096917c7e7433852d320a593348 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 13 Aug 2003 20:22:37 +0000 Subject: - added test for position_information via paths (This used to be commit 595be06a42bbf8b19feb1b7a7fc4389a6ad50ab8) --- source4/torture/raw/seek.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'source4') diff --git a/source4/torture/raw/seek.c b/source4/torture/raw/seek.c index a0980a7aea..7a69283347 100644 --- a/source4/torture/raw/seek.c +++ b/source4/torture/raw/seek.c @@ -145,6 +145,26 @@ static BOOL test_seek(struct cli_state *cli, TALLOC_CTX *mem_ctx) status = smb_raw_fileinfo(cli->tree, mem_ctx, &finfo); CHECK_STATUS(status, NT_STATUS_OK); CHECK_VALUE(finfo.position_information.out.position, 0); + + printf("position_information via paths\n"); + + sfinfo.generic.level = RAW_SFILEINFO_POSITION_INFORMATION; + sfinfo.position_information.file.fname = fname; + sfinfo.position_information.in.position = 32; + status = smb_raw_setpathinfo(cli->tree, &sfinfo); + CHECK_STATUS(status, NT_STATUS_OK); + + finfo.generic.level = RAW_FILEINFO_POSITION_INFORMATION; + finfo.position_information.in.fnum = fnum2; + status = smb_raw_fileinfo(cli->tree, mem_ctx, &finfo); + CHECK_STATUS(status, NT_STATUS_OK); + CHECK_VALUE(finfo.position_information.out.position, 25); + + finfo.generic.level = RAW_FILEINFO_POSITION_INFORMATION; + finfo.position_information.in.fname = fname; + status = smb_raw_pathinfo(cli->tree, mem_ctx, &finfo); + CHECK_STATUS(status, NT_STATUS_OK); + CHECK_VALUE(finfo.position_information.out.position, 0); done: -- cgit