summaryrefslogtreecommitdiff
path: root/source4/torture/raw
diff options
context:
space:
mode:
authorTim Prouty <tprouty@samba.org>2009-12-17 13:42:24 -0800
committerTim Prouty <tprouty@samba.org>2009-12-17 18:13:54 -0800
commitcfbf62dbfd18465d1a3f699cd22a35f9303f87fe (patch)
tree98df936eae30bd2377809765140924075b5252bc /source4/torture/raw
parentc3582f923e6adf2f3332540b062a2f994aeb7122 (diff)
downloadsamba-cfbf62dbfd18465d1a3f699cd22a35f9303f87fe.tar.gz
samba-cfbf62dbfd18465d1a3f699cd22a35f9303f87fe.tar.bz2
samba-cfbf62dbfd18465d1a3f699cd22a35f9303f87fe.zip
s4 torture: RAW-STREAMS-NAMES Make sure the create time of the streams are different from the base file
Diffstat (limited to 'source4/torture/raw')
-rw-r--r--source4/torture/raw/streams.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/source4/torture/raw/streams.c b/source4/torture/raw/streams.c
index 6e5479d967..79cacffe10 100644
--- a/source4/torture/raw/streams.c
+++ b/source4/torture/raw/streams.c
@@ -715,6 +715,30 @@ static bool test_stream_names(struct torture_context *tctx,
io.ntcreatex.in.open_disposition = NTCREATEX_DISP_CREATE;
io.ntcreatex.in.impersonation = NTCREATEX_IMPERSONATION_ANONYMOUS;
io.ntcreatex.in.security_flags = 0;
+ io.ntcreatex.in.fname = fname;
+
+ status = smb_raw_open(cli->tree, tctx, &io);
+ CHECK_STATUS(status, NT_STATUS_OK);
+ fnum1 = io.ntcreatex.out.file.fnum;
+
+ /*
+ * Make sure the create time of the streams are different from the
+ * base file.
+ */
+ sleep(2);
+ smbcli_close(cli->tree, fnum1);
+
+ io.generic.level = RAW_OPEN_NTCREATEX;
+ io.ntcreatex.in.root_fid.fnum = 0;
+ io.ntcreatex.in.flags = 0;
+ io.ntcreatex.in.access_mask = SEC_FILE_WRITE_DATA;
+ io.ntcreatex.in.create_options = 0;
+ io.ntcreatex.in.file_attr = FILE_ATTRIBUTE_NORMAL;
+ io.ntcreatex.in.share_access = 0;
+ io.ntcreatex.in.alloc_size = 0;
+ io.ntcreatex.in.open_disposition = NTCREATEX_DISP_CREATE;
+ io.ntcreatex.in.impersonation = NTCREATEX_IMPERSONATION_ANONYMOUS;
+ io.ntcreatex.in.security_flags = 0;
io.ntcreatex.in.fname = sname1;
status = smb_raw_open(cli->tree, tctx, &io);