diff options
Diffstat (limited to 'source4/torture/raw/close.c')
-rw-r--r-- | source4/torture/raw/close.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/source4/torture/raw/close.c b/source4/torture/raw/close.c index e19fe0f3cb..8a82a46acc 100644 --- a/source4/torture/raw/close.c +++ b/source4/torture/raw/close.c @@ -33,7 +33,7 @@ BOOL torture_raw_close(void) BOOL ret = True; TALLOC_CTX *mem_ctx; union smb_close io; - struct smb_flush io_flush; + union smb_flush io_flush; int fnum; const char *fname = "\\torture_close.txt"; time_t basetime = (time(NULL) + 3*86400) & ~1; @@ -65,7 +65,7 @@ BOOL torture_raw_close(void) REOPEN; io.close.level = RAW_CLOSE_CLOSE; - io.close.in.fnum = fnum; + io.close.file.fnum = fnum; io.close.in.write_time = basetime; status = smb_raw_close(cli->tree, &io); CHECK_STATUS(status, NT_STATUS_OK); @@ -76,8 +76,8 @@ BOOL torture_raw_close(void) printf("testing close.in.write_time\n"); /* the file should have the write time set */ - finfo.generic.in.fname = fname; finfo.generic.level = RAW_FILEINFO_ALL_INFO; + finfo.generic.file.path = fname; status = smb_raw_pathinfo(cli->tree, mem_ctx, &finfo); CHECK_STATUS(status, NT_STATUS_OK); @@ -107,20 +107,20 @@ BOOL torture_raw_close(void) smbcli_unlink(cli->tree, fname); REOPEN; - finfo2.generic.in.fname = fname; finfo2.generic.level = RAW_FILEINFO_ALL_INFO; + finfo2.generic.file.path = fname; status = smb_raw_pathinfo(cli->tree, mem_ctx, &finfo2); CHECK_STATUS(status, NT_STATUS_OK); io.close.level = RAW_CLOSE_CLOSE; - io.close.in.fnum = fnum; + io.close.file.fnum = fnum; io.close.in.write_time = 0; status = smb_raw_close(cli->tree, &io); CHECK_STATUS(status, NT_STATUS_OK); /* the file should have the write time set equal to access time */ - finfo.generic.in.fname = fname; finfo.generic.level = RAW_FILEINFO_ALL_INFO; + finfo.generic.file.path = fname; status = smb_raw_pathinfo(cli->tree, mem_ctx, &finfo); CHECK_STATUS(status, NT_STATUS_OK); @@ -136,31 +136,31 @@ BOOL torture_raw_close(void) /* check splclose on a file */ REOPEN; io.splclose.level = RAW_CLOSE_SPLCLOSE; - io.splclose.in.fnum = fnum; + io.splclose.file.fnum = fnum; status = smb_raw_close(cli->tree, &io); CHECK_STATUS(status, NT_STATUS_DOS(ERRSRV, ERRerror)); printf("testing flush\n"); smbcli_close(cli->tree, fnum); - io_flush.in.fnum = fnum; + io_flush.flush.file.fnum = fnum; status = smb_raw_flush(cli->tree, &io_flush); CHECK_STATUS(status, NT_STATUS_INVALID_HANDLE); - io_flush.in.fnum = 0xffff; + io_flush.flush.file.fnum = 0xffff; status = smb_raw_flush(cli->tree, &io_flush); CHECK_STATUS(status, NT_STATUS_OK); REOPEN; - io_flush.in.fnum = fnum; + io_flush.flush.file.fnum = fnum; status = smb_raw_flush(cli->tree, &io_flush); CHECK_STATUS(status, NT_STATUS_OK); printf("Testing SMBexit\n"); smb_raw_exit(cli->session); - io_flush.in.fnum = fnum; + io_flush.flush.file.fnum = fnum; status = smb_raw_flush(cli->tree, &io_flush); CHECK_STATUS(status, NT_STATUS_INVALID_HANDLE); |